• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Adyen / adyen-java-api-library / #2841

10 Nov 2023 09:29AM UTC coverage: 12.829%. First build
#2841

push

web-flow
Merge f5e54db9e into 5fe92c1d1

2 of 200 new or added lines in 10 files covered. (1.0%)

12395 of 96617 relevant lines covered (12.83%)

0.13 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/main/java/com/adyen/model/configurationwebhooks/AccountHolderCapability.java
1
/*
2
 * Configuration webhooks
3
 *
4
 * The version of the OpenAPI document: 1
5
 * 
6
 *
7
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
8
 * https://openapi-generator.tech
9
 * Do not edit the class manually.
10
 */
11

12

13
package com.adyen.model.configurationwebhooks;
14

15
import java.util.Objects;
16
import java.util.Arrays;
17
import java.util.Map;
18
import java.util.HashMap;
19
import com.adyen.model.configurationwebhooks.CapabilityProblem;
20
import com.adyen.model.configurationwebhooks.CapabilitySettings;
21
import com.fasterxml.jackson.annotation.JsonInclude;
22
import com.fasterxml.jackson.annotation.JsonProperty;
23
import com.fasterxml.jackson.annotation.JsonCreator;
24
import com.fasterxml.jackson.annotation.JsonTypeName;
25
import com.fasterxml.jackson.annotation.JsonValue;
26
import io.swagger.annotations.ApiModel;
27
import io.swagger.annotations.ApiModelProperty;
28
import java.util.ArrayList;
29
import java.util.List;
30
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
31
import com.fasterxml.jackson.core.JsonProcessingException;
32

33

34
/**
35
 * AccountHolderCapability
36
 */
37
@JsonPropertyOrder({
38
  AccountHolderCapability.JSON_PROPERTY_ALLOWED,
39
  AccountHolderCapability.JSON_PROPERTY_ALLOWED_LEVEL,
40
  AccountHolderCapability.JSON_PROPERTY_ALLOWED_SETTINGS,
41
  AccountHolderCapability.JSON_PROPERTY_ENABLED,
42
  AccountHolderCapability.JSON_PROPERTY_PROBLEMS,
43
  AccountHolderCapability.JSON_PROPERTY_REQUESTED,
44
  AccountHolderCapability.JSON_PROPERTY_REQUESTED_LEVEL,
45
  AccountHolderCapability.JSON_PROPERTY_REQUESTED_SETTINGS,
46
  AccountHolderCapability.JSON_PROPERTY_VERIFICATION_STATUS
47
})
48

49
public class AccountHolderCapability {
50
  public static final String JSON_PROPERTY_ALLOWED = "allowed";
51
  private Boolean allowed;
52

53
  /**
54
   * The capability level that is allowed for the account holder.  Possible values: **notApplicable**, **low**, **medium**, **high**.
55
   */
56
  public enum AllowedLevelEnum {
×
57
    HIGH("high"),
×
58
    
59
    LOW("low"),
×
60
    
61
    MEDIUM("medium"),
×
62
    
63
    NOTAPPLICABLE("notApplicable");
×
64

65
    private String value;
66

67
    AllowedLevelEnum(String value) {
×
68
      this.value = value;
×
69
    }
×
70

71
    @JsonValue
72
    public String getValue() {
73
      return value;
×
74
    }
75

76
    @Override
77
    public String toString() {
78
      return String.valueOf(value);
×
79
    }
80

81
    @JsonCreator
82
    public static AllowedLevelEnum fromValue(String value) {
83
      for (AllowedLevelEnum b : AllowedLevelEnum.values()) {
×
84
        if (b.value.equals(value)) {
×
85
          return b;
×
86
        }
87
      }
88
      throw new IllegalArgumentException("Unexpected value '" + value + "'");
×
89
    }
90
  }
91

92
  public static final String JSON_PROPERTY_ALLOWED_LEVEL = "allowedLevel";
93
  private AllowedLevelEnum allowedLevel;
94

95
  public static final String JSON_PROPERTY_ALLOWED_SETTINGS = "allowedSettings";
96
  private CapabilitySettings allowedSettings;
97

98
  public static final String JSON_PROPERTY_ENABLED = "enabled";
99
  private Boolean enabled;
100

101
  public static final String JSON_PROPERTY_PROBLEMS = "problems";
102
  private List<CapabilityProblem> problems = null;
×
103

104
  public static final String JSON_PROPERTY_REQUESTED = "requested";
105
  private Boolean requested;
106

107
  /**
108
   * The requested level of the capability. Some capabilities, such as those used in [card issuing](https://docs.adyen.com/issuing/add-capabilities#capability-levels), have different levels. Levels increase the capability, but also require additional checks and increased monitoring.  Possible values: **notApplicable**, **low**, **medium**, **high**.
109
   */
110
  public enum RequestedLevelEnum {
×
111
    HIGH("high"),
×
112
    
113
    LOW("low"),
×
114
    
115
    MEDIUM("medium"),
×
116
    
117
    NOTAPPLICABLE("notApplicable");
×
118

119
    private String value;
120

121
    RequestedLevelEnum(String value) {
×
122
      this.value = value;
×
123
    }
×
124

125
    @JsonValue
126
    public String getValue() {
127
      return value;
×
128
    }
129

130
    @Override
131
    public String toString() {
132
      return String.valueOf(value);
×
133
    }
134

135
    @JsonCreator
136
    public static RequestedLevelEnum fromValue(String value) {
137
      for (RequestedLevelEnum b : RequestedLevelEnum.values()) {
×
138
        if (b.value.equals(value)) {
×
139
          return b;
×
140
        }
141
      }
142
      throw new IllegalArgumentException("Unexpected value '" + value + "'");
×
143
    }
144
  }
145

146
  public static final String JSON_PROPERTY_REQUESTED_LEVEL = "requestedLevel";
147
  private RequestedLevelEnum requestedLevel;
148

149
  public static final String JSON_PROPERTY_REQUESTED_SETTINGS = "requestedSettings";
150
  private CapabilitySettings requestedSettings;
151

152
  /**
153
   * The status of the verification checks for the capability.  Possible values:  * **pending**: Adyen is running the verification.  * **invalid**: The verification failed. Check if the &#x60;errors&#x60; array contains more information.  * **valid**: The verification has been successfully completed.  * **rejected**: Adyen has verified the information, but found reasons to not allow the capability. 
154
   */
155
  public enum VerificationStatusEnum {
×
156
    INVALID("invalid"),
×
157
    
158
    PENDING("pending"),
×
159
    
160
    REJECTED("rejected"),
×
161
    
162
    VALID("valid");
×
163

164
    private String value;
165

166
    VerificationStatusEnum(String value) {
×
167
      this.value = value;
×
168
    }
×
169

170
    @JsonValue
171
    public String getValue() {
172
      return value;
×
173
    }
174

175
    @Override
176
    public String toString() {
177
      return String.valueOf(value);
×
178
    }
179

180
    @JsonCreator
181
    public static VerificationStatusEnum fromValue(String value) {
182
      for (VerificationStatusEnum b : VerificationStatusEnum.values()) {
×
183
        if (b.value.equals(value)) {
×
184
          return b;
×
185
        }
186
      }
187
      throw new IllegalArgumentException("Unexpected value '" + value + "'");
×
188
    }
189
  }
190

191
  public static final String JSON_PROPERTY_VERIFICATION_STATUS = "verificationStatus";
192
  private VerificationStatusEnum verificationStatus;
193

194
  public AccountHolderCapability() { 
×
195
  }
×
196

197
  public AccountHolderCapability allowed(Boolean allowed) {
198
    this.allowed = allowed;
×
199
    return this;
×
200
  }
201

202
   /**
203
   * Indicates whether the capability is allowed. Adyen sets this to **true** if the verification is successful and the account holder is permitted to use the capability.
204
   * @return allowed
205
  **/
206
  @ApiModelProperty(value = "Indicates whether the capability is allowed. Adyen sets this to **true** if the verification is successful and the account holder is permitted to use the capability.")
207
  @JsonProperty(JSON_PROPERTY_ALLOWED)
208
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
209

210
  public Boolean getAllowed() {
211
    return allowed;
×
212
  }
213

214

215
  @JsonProperty(JSON_PROPERTY_ALLOWED)
216
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
217
  public void setAllowed(Boolean allowed) {
218
    this.allowed = allowed;
×
219
  }
×
220

221

222
  public AccountHolderCapability allowedLevel(AllowedLevelEnum allowedLevel) {
223
    this.allowedLevel = allowedLevel;
×
224
    return this;
×
225
  }
226

227
   /**
228
   * The capability level that is allowed for the account holder.  Possible values: **notApplicable**, **low**, **medium**, **high**.
229
   * @return allowedLevel
230
  **/
231
  @ApiModelProperty(value = "The capability level that is allowed for the account holder.  Possible values: **notApplicable**, **low**, **medium**, **high**.")
232
  @JsonProperty(JSON_PROPERTY_ALLOWED_LEVEL)
233
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
234

235
  public AllowedLevelEnum getAllowedLevel() {
236
    return allowedLevel;
×
237
  }
238

239

240
  @JsonProperty(JSON_PROPERTY_ALLOWED_LEVEL)
241
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
242
  public void setAllowedLevel(AllowedLevelEnum allowedLevel) {
243
    this.allowedLevel = allowedLevel;
×
244
  }
×
245

246

247
  public AccountHolderCapability allowedSettings(CapabilitySettings allowedSettings) {
248
    this.allowedSettings = allowedSettings;
×
249
    return this;
×
250
  }
251

252
   /**
253
   * Get allowedSettings
254
   * @return allowedSettings
255
  **/
256
  @ApiModelProperty(value = "")
257
  @JsonProperty(JSON_PROPERTY_ALLOWED_SETTINGS)
258
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
259

260
  public CapabilitySettings getAllowedSettings() {
261
    return allowedSettings;
×
262
  }
263

264

265
  @JsonProperty(JSON_PROPERTY_ALLOWED_SETTINGS)
266
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
267
  public void setAllowedSettings(CapabilitySettings allowedSettings) {
268
    this.allowedSettings = allowedSettings;
×
269
  }
×
270

271

272
  public AccountHolderCapability enabled(Boolean enabled) {
273
    this.enabled = enabled;
×
274
    return this;
×
275
  }
276

277
   /**
278
   * Indicates whether the capability is enabled. If **false**, the capability is temporarily disabled for the account holder.
279
   * @return enabled
280
  **/
281
  @ApiModelProperty(value = "Indicates whether the capability is enabled. If **false**, the capability is temporarily disabled for the account holder.")
282
  @JsonProperty(JSON_PROPERTY_ENABLED)
283
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
284

285
  public Boolean getEnabled() {
286
    return enabled;
×
287
  }
288

289

290
  @JsonProperty(JSON_PROPERTY_ENABLED)
291
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
292
  public void setEnabled(Boolean enabled) {
293
    this.enabled = enabled;
×
294
  }
×
295

296

297
  public AccountHolderCapability problems(List<CapabilityProblem> problems) {
298
    this.problems = problems;
×
299
    return this;
×
300
  }
301

302
  public AccountHolderCapability addProblemsItem(CapabilityProblem problemsItem) {
303
    if (this.problems == null) {
×
304
      this.problems = new ArrayList<>();
×
305
    }
306
    this.problems.add(problemsItem);
×
307
    return this;
×
308
  }
309

310
   /**
311
   * Contains verification errors and the actions that you can take to resolve them.
312
   * @return problems
313
  **/
314
  @ApiModelProperty(value = "Contains verification errors and the actions that you can take to resolve them.")
315
  @JsonProperty(JSON_PROPERTY_PROBLEMS)
316
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
317

318
  public List<CapabilityProblem> getProblems() {
319
    return problems;
×
320
  }
321

322

323
  @JsonProperty(JSON_PROPERTY_PROBLEMS)
324
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
325
  public void setProblems(List<CapabilityProblem> problems) {
326
    this.problems = problems;
×
327
  }
×
328

329

330
  public AccountHolderCapability requested(Boolean requested) {
331
    this.requested = requested;
×
332
    return this;
×
333
  }
334

335
   /**
336
   * Indicates whether the capability is requested. To check whether the account holder is permitted to use the capability, refer to the &#x60;allowed&#x60; field.
337
   * @return requested
338
  **/
339
  @ApiModelProperty(value = "Indicates whether the capability is requested. To check whether the account holder is permitted to use the capability, refer to the `allowed` field.")
340
  @JsonProperty(JSON_PROPERTY_REQUESTED)
341
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
342

343
  public Boolean getRequested() {
344
    return requested;
×
345
  }
346

347

348
  @JsonProperty(JSON_PROPERTY_REQUESTED)
349
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
350
  public void setRequested(Boolean requested) {
351
    this.requested = requested;
×
352
  }
×
353

354

355
  public AccountHolderCapability requestedLevel(RequestedLevelEnum requestedLevel) {
356
    this.requestedLevel = requestedLevel;
×
357
    return this;
×
358
  }
359

360
   /**
361
   * The requested level of the capability. Some capabilities, such as those used in [card issuing](https://docs.adyen.com/issuing/add-capabilities#capability-levels), have different levels. Levels increase the capability, but also require additional checks and increased monitoring.  Possible values: **notApplicable**, **low**, **medium**, **high**.
362
   * @return requestedLevel
363
  **/
364
  @ApiModelProperty(value = "The requested level of the capability. Some capabilities, such as those used in [card issuing](https://docs.adyen.com/issuing/add-capabilities#capability-levels), have different levels. Levels increase the capability, but also require additional checks and increased monitoring.  Possible values: **notApplicable**, **low**, **medium**, **high**.")
365
  @JsonProperty(JSON_PROPERTY_REQUESTED_LEVEL)
366
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
367

368
  public RequestedLevelEnum getRequestedLevel() {
369
    return requestedLevel;
×
370
  }
371

372

373
  @JsonProperty(JSON_PROPERTY_REQUESTED_LEVEL)
374
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
375
  public void setRequestedLevel(RequestedLevelEnum requestedLevel) {
376
    this.requestedLevel = requestedLevel;
×
377
  }
×
378

379

380
  public AccountHolderCapability requestedSettings(CapabilitySettings requestedSettings) {
381
    this.requestedSettings = requestedSettings;
×
382
    return this;
×
383
  }
384

385
   /**
386
   * Get requestedSettings
387
   * @return requestedSettings
388
  **/
389
  @ApiModelProperty(value = "")
390
  @JsonProperty(JSON_PROPERTY_REQUESTED_SETTINGS)
391
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
392

393
  public CapabilitySettings getRequestedSettings() {
394
    return requestedSettings;
×
395
  }
396

397

398
  @JsonProperty(JSON_PROPERTY_REQUESTED_SETTINGS)
399
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
400
  public void setRequestedSettings(CapabilitySettings requestedSettings) {
401
    this.requestedSettings = requestedSettings;
×
402
  }
×
403

404

405
  public AccountHolderCapability verificationStatus(VerificationStatusEnum verificationStatus) {
406
    this.verificationStatus = verificationStatus;
×
407
    return this;
×
408
  }
409

410
   /**
411
   * The status of the verification checks for the capability.  Possible values:  * **pending**: Adyen is running the verification.  * **invalid**: The verification failed. Check if the &#x60;errors&#x60; array contains more information.  * **valid**: The verification has been successfully completed.  * **rejected**: Adyen has verified the information, but found reasons to not allow the capability. 
412
   * @return verificationStatus
413
  **/
414
  @ApiModelProperty(value = "The status of the verification checks for the capability.  Possible values:  * **pending**: Adyen is running the verification.  * **invalid**: The verification failed. Check if the `errors` array contains more information.  * **valid**: The verification has been successfully completed.  * **rejected**: Adyen has verified the information, but found reasons to not allow the capability. ")
415
  @JsonProperty(JSON_PROPERTY_VERIFICATION_STATUS)
416
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
417

418
  public VerificationStatusEnum getVerificationStatus() {
419
    return verificationStatus;
×
420
  }
421

422

423
  @JsonProperty(JSON_PROPERTY_VERIFICATION_STATUS)
424
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
425
  public void setVerificationStatus(VerificationStatusEnum verificationStatus) {
426
    this.verificationStatus = verificationStatus;
×
427
  }
×
428

429

430
  /**
431
   * Return true if this AccountHolderCapability object is equal to o.
432
   */
433
  @Override
434
  public boolean equals(Object o) {
435
    if (this == o) {
×
436
      return true;
×
437
    }
438
    if (o == null || getClass() != o.getClass()) {
×
439
      return false;
×
440
    }
441
    AccountHolderCapability accountHolderCapability = (AccountHolderCapability) o;
×
442
    return Objects.equals(this.allowed, accountHolderCapability.allowed) &&
×
443
        Objects.equals(this.allowedLevel, accountHolderCapability.allowedLevel) &&
×
444
        Objects.equals(this.allowedSettings, accountHolderCapability.allowedSettings) &&
×
445
        Objects.equals(this.enabled, accountHolderCapability.enabled) &&
×
446
        Objects.equals(this.problems, accountHolderCapability.problems) &&
×
447
        Objects.equals(this.requested, accountHolderCapability.requested) &&
×
448
        Objects.equals(this.requestedLevel, accountHolderCapability.requestedLevel) &&
×
449
        Objects.equals(this.requestedSettings, accountHolderCapability.requestedSettings) &&
×
450
        Objects.equals(this.verificationStatus, accountHolderCapability.verificationStatus);
×
451
  }
452

453
  @Override
454
  public int hashCode() {
NEW
455
    return Objects.hash(allowed, allowedLevel, allowedSettings, enabled, problems, requested, requestedLevel, requestedSettings, verificationStatus);
×
456
  }
457

458
  @Override
459
  public String toString() {
460
    StringBuilder sb = new StringBuilder();
×
461
    sb.append("class AccountHolderCapability {\n");
×
462
    sb.append("    allowed: ").append(toIndentedString(allowed)).append("\n");
×
463
    sb.append("    allowedLevel: ").append(toIndentedString(allowedLevel)).append("\n");
×
464
    sb.append("    allowedSettings: ").append(toIndentedString(allowedSettings)).append("\n");
×
465
    sb.append("    enabled: ").append(toIndentedString(enabled)).append("\n");
×
466
    sb.append("    problems: ").append(toIndentedString(problems)).append("\n");
×
467
    sb.append("    requested: ").append(toIndentedString(requested)).append("\n");
×
468
    sb.append("    requestedLevel: ").append(toIndentedString(requestedLevel)).append("\n");
×
469
    sb.append("    requestedSettings: ").append(toIndentedString(requestedSettings)).append("\n");
×
470
    sb.append("    verificationStatus: ").append(toIndentedString(verificationStatus)).append("\n");
×
471
    sb.append("}");
×
472
    return sb.toString();
×
473
  }
474

475
  /**
476
   * Convert the given object to string with each line indented by 4 spaces
477
   * (except the first line).
478
   */
479
  private String toIndentedString(Object o) {
480
    if (o == null) {
×
481
      return "null";
×
482
    }
483
    return o.toString().replace("\n", "\n    ");
×
484
  }
485

486
/**
487
   * Create an instance of AccountHolderCapability given an JSON string
488
   *
489
   * @param jsonString JSON string
490
   * @return An instance of AccountHolderCapability
491
   * @throws JsonProcessingException if the JSON string is invalid with respect to AccountHolderCapability
492
   */
493
  public static AccountHolderCapability fromJson(String jsonString) throws JsonProcessingException {
494
    return JSON.getMapper().readValue(jsonString, AccountHolderCapability.class);
×
495
  }
496
/**
497
  * Convert an instance of AccountHolderCapability to an JSON string
498
  *
499
  * @return JSON string
500
  */
501
  public String toJson() throws JsonProcessingException {
502
    return JSON.getMapper().writeValueAsString(this);
×
503
  }
504
}
505

STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc