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

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

18 Sep 2023 12:27PM UTC coverage: 13.146%. First build
#2660

push

web-flow
Merge fdf590561 into ba706cfa8

2480 of 2480 new or added lines in 54 files covered. (100.0%)

10283 of 78224 relevant lines covered (13.15%)

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.AccountSupportingEntityCapability;
20
import com.adyen.model.configurationwebhooks.CapabilityProblem;
21
import com.adyen.model.configurationwebhooks.CapabilitySettings;
22
import com.fasterxml.jackson.annotation.JsonInclude;
23
import com.fasterxml.jackson.annotation.JsonProperty;
24
import com.fasterxml.jackson.annotation.JsonCreator;
25
import com.fasterxml.jackson.annotation.JsonTypeName;
26
import com.fasterxml.jackson.annotation.JsonValue;
27
import io.swagger.annotations.ApiModel;
28
import io.swagger.annotations.ApiModelProperty;
29
import java.util.ArrayList;
30
import java.util.List;
31
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
32
import com.fasterxml.jackson.core.JsonProcessingException;
33

34

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

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

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

67
    private String value;
68

69
    AllowedLevelEnum(String value) {
×
70
      this.value = value;
×
71
    }
×
72

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

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

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

94
  public static final String JSON_PROPERTY_ALLOWED_LEVEL = "allowedLevel";
95
  private AllowedLevelEnum allowedLevel;
96

97
  public static final String JSON_PROPERTY_ALLOWED_SETTINGS = "allowedSettings";
98
  private CapabilitySettings allowedSettings;
99

100
  public static final String JSON_PROPERTY_ENABLED = "enabled";
101
  private Boolean enabled;
102

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

106
  public static final String JSON_PROPERTY_REQUESTED = "requested";
107
  private Boolean requested;
108

109
  /**
110
   * 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**.
111
   */
112
  public enum RequestedLevelEnum {
×
113
    HIGH("high"),
×
114
    
115
    LOW("low"),
×
116
    
117
    MEDIUM("medium"),
×
118
    
119
    NOTAPPLICABLE("notApplicable");
×
120

121
    private String value;
122

123
    RequestedLevelEnum(String value) {
×
124
      this.value = value;
×
125
    }
×
126

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

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

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

148
  public static final String JSON_PROPERTY_REQUESTED_LEVEL = "requestedLevel";
149
  private RequestedLevelEnum requestedLevel;
150

151
  public static final String JSON_PROPERTY_REQUESTED_SETTINGS = "requestedSettings";
152
  private CapabilitySettings requestedSettings;
153

154
  public static final String JSON_PROPERTY_TRANSFER_INSTRUMENTS = "transferInstruments";
155
  private List<AccountSupportingEntityCapability> transferInstruments = null;
×
156

157
  /**
158
   * 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. 
159
   */
160
  public enum VerificationStatusEnum {
×
161
    INVALID("invalid"),
×
162
    
163
    PENDING("pending"),
×
164
    
165
    REJECTED("rejected"),
×
166
    
167
    VALID("valid");
×
168

169
    private String value;
170

171
    VerificationStatusEnum(String value) {
×
172
      this.value = value;
×
173
    }
×
174

175
    @JsonValue
176
    public String getValue() {
177
      return value;
×
178
    }
179

180
    @Override
181
    public String toString() {
182
      return String.valueOf(value);
×
183
    }
184

185
    @JsonCreator
186
    public static VerificationStatusEnum fromValue(String value) {
187
      for (VerificationStatusEnum b : VerificationStatusEnum.values()) {
×
188
        if (b.value.equals(value)) {
×
189
          return b;
×
190
        }
191
      }
192
      throw new IllegalArgumentException("Unexpected value '" + value + "'");
×
193
    }
194
  }
195

196
  public static final String JSON_PROPERTY_VERIFICATION_STATUS = "verificationStatus";
197
  private VerificationStatusEnum verificationStatus;
198

199
  public AccountHolderCapability() { 
×
200
  }
×
201

202
  public AccountHolderCapability allowed(Boolean allowed) {
203
    this.allowed = allowed;
×
204
    return this;
×
205
  }
206

207
   /**
208
   * 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.
209
   * @return allowed
210
  **/
211
  @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.")
212
  @JsonProperty(JSON_PROPERTY_ALLOWED)
213
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
214

215
  public Boolean getAllowed() {
216
    return allowed;
×
217
  }
218

219

220
  @JsonProperty(JSON_PROPERTY_ALLOWED)
221
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
222
  public void setAllowed(Boolean allowed) {
223
    this.allowed = allowed;
×
224
  }
×
225

226

227
  public AccountHolderCapability allowedLevel(AllowedLevelEnum allowedLevel) {
228
    this.allowedLevel = allowedLevel;
×
229
    return this;
×
230
  }
231

232
   /**
233
   * The capability level that is allowed for the account holder.  Possible values: **notApplicable**, **low**, **medium**, **high**.
234
   * @return allowedLevel
235
  **/
236
  @ApiModelProperty(value = "The capability level that is allowed for the account holder.  Possible values: **notApplicable**, **low**, **medium**, **high**.")
237
  @JsonProperty(JSON_PROPERTY_ALLOWED_LEVEL)
238
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
239

240
  public AllowedLevelEnum getAllowedLevel() {
241
    return allowedLevel;
×
242
  }
243

244

245
  @JsonProperty(JSON_PROPERTY_ALLOWED_LEVEL)
246
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
247
  public void setAllowedLevel(AllowedLevelEnum allowedLevel) {
248
    this.allowedLevel = allowedLevel;
×
249
  }
×
250

251

252
  public AccountHolderCapability allowedSettings(CapabilitySettings allowedSettings) {
253
    this.allowedSettings = allowedSettings;
×
254
    return this;
×
255
  }
256

257
   /**
258
   * Get allowedSettings
259
   * @return allowedSettings
260
  **/
261
  @ApiModelProperty(value = "")
262
  @JsonProperty(JSON_PROPERTY_ALLOWED_SETTINGS)
263
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
264

265
  public CapabilitySettings getAllowedSettings() {
266
    return allowedSettings;
×
267
  }
268

269

270
  @JsonProperty(JSON_PROPERTY_ALLOWED_SETTINGS)
271
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
272
  public void setAllowedSettings(CapabilitySettings allowedSettings) {
273
    this.allowedSettings = allowedSettings;
×
274
  }
×
275

276

277
  public AccountHolderCapability enabled(Boolean enabled) {
278
    this.enabled = enabled;
×
279
    return this;
×
280
  }
281

282
   /**
283
   * Indicates whether the capability is enabled. If **false**, the capability is temporarily disabled for the account holder.
284
   * @return enabled
285
  **/
286
  @ApiModelProperty(value = "Indicates whether the capability is enabled. If **false**, the capability is temporarily disabled for the account holder.")
287
  @JsonProperty(JSON_PROPERTY_ENABLED)
288
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
289

290
  public Boolean getEnabled() {
291
    return enabled;
×
292
  }
293

294

295
  @JsonProperty(JSON_PROPERTY_ENABLED)
296
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
297
  public void setEnabled(Boolean enabled) {
298
    this.enabled = enabled;
×
299
  }
×
300

301

302
  public AccountHolderCapability problems(List<CapabilityProblem> problems) {
303
    this.problems = problems;
×
304
    return this;
×
305
  }
306

307
  public AccountHolderCapability addProblemsItem(CapabilityProblem problemsItem) {
308
    if (this.problems == null) {
×
309
      this.problems = new ArrayList<>();
×
310
    }
311
    this.problems.add(problemsItem);
×
312
    return this;
×
313
  }
314

315
   /**
316
   * Contains verification errors and the actions that you can take to resolve them.
317
   * @return problems
318
  **/
319
  @ApiModelProperty(value = "Contains verification errors and the actions that you can take to resolve them.")
320
  @JsonProperty(JSON_PROPERTY_PROBLEMS)
321
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
322

323
  public List<CapabilityProblem> getProblems() {
324
    return problems;
×
325
  }
326

327

328
  @JsonProperty(JSON_PROPERTY_PROBLEMS)
329
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
330
  public void setProblems(List<CapabilityProblem> problems) {
331
    this.problems = problems;
×
332
  }
×
333

334

335
  public AccountHolderCapability requested(Boolean requested) {
336
    this.requested = requested;
×
337
    return this;
×
338
  }
339

340
   /**
341
   * 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.
342
   * @return requested
343
  **/
344
  @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.")
345
  @JsonProperty(JSON_PROPERTY_REQUESTED)
346
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
347

348
  public Boolean getRequested() {
349
    return requested;
×
350
  }
351

352

353
  @JsonProperty(JSON_PROPERTY_REQUESTED)
354
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
355
  public void setRequested(Boolean requested) {
356
    this.requested = requested;
×
357
  }
×
358

359

360
  public AccountHolderCapability requestedLevel(RequestedLevelEnum requestedLevel) {
361
    this.requestedLevel = requestedLevel;
×
362
    return this;
×
363
  }
364

365
   /**
366
   * 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**.
367
   * @return requestedLevel
368
  **/
369
  @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**.")
370
  @JsonProperty(JSON_PROPERTY_REQUESTED_LEVEL)
371
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
372

373
  public RequestedLevelEnum getRequestedLevel() {
374
    return requestedLevel;
×
375
  }
376

377

378
  @JsonProperty(JSON_PROPERTY_REQUESTED_LEVEL)
379
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
380
  public void setRequestedLevel(RequestedLevelEnum requestedLevel) {
381
    this.requestedLevel = requestedLevel;
×
382
  }
×
383

384

385
  public AccountHolderCapability requestedSettings(CapabilitySettings requestedSettings) {
386
    this.requestedSettings = requestedSettings;
×
387
    return this;
×
388
  }
389

390
   /**
391
   * Get requestedSettings
392
   * @return requestedSettings
393
  **/
394
  @ApiModelProperty(value = "")
395
  @JsonProperty(JSON_PROPERTY_REQUESTED_SETTINGS)
396
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
397

398
  public CapabilitySettings getRequestedSettings() {
399
    return requestedSettings;
×
400
  }
401

402

403
  @JsonProperty(JSON_PROPERTY_REQUESTED_SETTINGS)
404
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
405
  public void setRequestedSettings(CapabilitySettings requestedSettings) {
406
    this.requestedSettings = requestedSettings;
×
407
  }
×
408

409

410
  public AccountHolderCapability transferInstruments(List<AccountSupportingEntityCapability> transferInstruments) {
411
    this.transferInstruments = transferInstruments;
×
412
    return this;
×
413
  }
414

415
  public AccountHolderCapability addTransferInstrumentsItem(AccountSupportingEntityCapability transferInstrumentsItem) {
416
    if (this.transferInstruments == null) {
×
417
      this.transferInstruments = new ArrayList<>();
×
418
    }
419
    this.transferInstruments.add(transferInstrumentsItem);
×
420
    return this;
×
421
  }
422

423
   /**
424
   * Contains the status of the transfer instruments associated with this capability. 
425
   * @return transferInstruments
426
  **/
427
  @ApiModelProperty(value = "Contains the status of the transfer instruments associated with this capability. ")
428
  @JsonProperty(JSON_PROPERTY_TRANSFER_INSTRUMENTS)
429
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
430

431
  public List<AccountSupportingEntityCapability> getTransferInstruments() {
432
    return transferInstruments;
×
433
  }
434

435

436
  @JsonProperty(JSON_PROPERTY_TRANSFER_INSTRUMENTS)
437
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
438
  public void setTransferInstruments(List<AccountSupportingEntityCapability> transferInstruments) {
439
    this.transferInstruments = transferInstruments;
×
440
  }
×
441

442

443
  public AccountHolderCapability verificationStatus(VerificationStatusEnum verificationStatus) {
444
    this.verificationStatus = verificationStatus;
×
445
    return this;
×
446
  }
447

448
   /**
449
   * 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. 
450
   * @return verificationStatus
451
  **/
452
  @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. ")
453
  @JsonProperty(JSON_PROPERTY_VERIFICATION_STATUS)
454
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
455

456
  public VerificationStatusEnum getVerificationStatus() {
457
    return verificationStatus;
×
458
  }
459

460

461
  @JsonProperty(JSON_PROPERTY_VERIFICATION_STATUS)
462
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
463
  public void setVerificationStatus(VerificationStatusEnum verificationStatus) {
464
    this.verificationStatus = verificationStatus;
×
465
  }
×
466

467

468
  /**
469
   * Return true if this AccountHolderCapability object is equal to o.
470
   */
471
  @Override
472
  public boolean equals(Object o) {
473
    if (this == o) {
×
474
      return true;
×
475
    }
476
    if (o == null || getClass() != o.getClass()) {
×
477
      return false;
×
478
    }
479
    AccountHolderCapability accountHolderCapability = (AccountHolderCapability) o;
×
480
    return Objects.equals(this.allowed, accountHolderCapability.allowed) &&
×
481
        Objects.equals(this.allowedLevel, accountHolderCapability.allowedLevel) &&
×
482
        Objects.equals(this.allowedSettings, accountHolderCapability.allowedSettings) &&
×
483
        Objects.equals(this.enabled, accountHolderCapability.enabled) &&
×
484
        Objects.equals(this.problems, accountHolderCapability.problems) &&
×
485
        Objects.equals(this.requested, accountHolderCapability.requested) &&
×
486
        Objects.equals(this.requestedLevel, accountHolderCapability.requestedLevel) &&
×
487
        Objects.equals(this.requestedSettings, accountHolderCapability.requestedSettings) &&
×
488
        Objects.equals(this.transferInstruments, accountHolderCapability.transferInstruments) &&
×
489
        Objects.equals(this.verificationStatus, accountHolderCapability.verificationStatus);
×
490
  }
491

492
  @Override
493
  public int hashCode() {
494
    return Objects.hash(allowed, allowedLevel, allowedSettings, enabled, problems, requested, requestedLevel, requestedSettings, transferInstruments, verificationStatus);
×
495
  }
496

497
  @Override
498
  public String toString() {
499
    StringBuilder sb = new StringBuilder();
×
500
    sb.append("class AccountHolderCapability {\n");
×
501
    sb.append("    allowed: ").append(toIndentedString(allowed)).append("\n");
×
502
    sb.append("    allowedLevel: ").append(toIndentedString(allowedLevel)).append("\n");
×
503
    sb.append("    allowedSettings: ").append(toIndentedString(allowedSettings)).append("\n");
×
504
    sb.append("    enabled: ").append(toIndentedString(enabled)).append("\n");
×
505
    sb.append("    problems: ").append(toIndentedString(problems)).append("\n");
×
506
    sb.append("    requested: ").append(toIndentedString(requested)).append("\n");
×
507
    sb.append("    requestedLevel: ").append(toIndentedString(requestedLevel)).append("\n");
×
508
    sb.append("    requestedSettings: ").append(toIndentedString(requestedSettings)).append("\n");
×
509
    sb.append("    transferInstruments: ").append(toIndentedString(transferInstruments)).append("\n");
×
510
    sb.append("    verificationStatus: ").append(toIndentedString(verificationStatus)).append("\n");
×
511
    sb.append("}");
×
512
    return sb.toString();
×
513
  }
514

515
  /**
516
   * Convert the given object to string with each line indented by 4 spaces
517
   * (except the first line).
518
   */
519
  private String toIndentedString(Object o) {
520
    if (o == null) {
×
521
      return "null";
×
522
    }
523
    return o.toString().replace("\n", "\n    ");
×
524
  }
525

526
/**
527
   * Create an instance of AccountHolderCapability given an JSON string
528
   *
529
   * @param jsonString JSON string
530
   * @return An instance of AccountHolderCapability
531
   * @throws JsonProcessingException if the JSON string is invalid with respect to AccountHolderCapability
532
   */
533
  public static AccountHolderCapability fromJson(String jsonString) throws JsonProcessingException {
534
    return JSON.getMapper().readValue(jsonString, AccountHolderCapability.class);
×
535
  }
536
/**
537
  * Convert an instance of AccountHolderCapability to an JSON string
538
  *
539
  * @return JSON string
540
  */
541
  public String toJson() throws JsonProcessingException {
542
    return JSON.getMapper().writeValueAsString(this);
×
543
  }
544
}
545

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