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

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

14 Jun 2024 07:13AM UTC coverage: 11.966%. First build
#3322

push

web-flow
Merge 673aaf237 into ac91e3ca5

6 of 369 new or added lines in 46 files covered. (1.63%)

12491 of 104390 relevant lines covered (11.97%)

0.12 hits per line

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

24.24
/src/main/java/com/adyen/model/checkout/DragonpayDetails.java
1
/*
2
 * Adyen Checkout API
3
 *
4
 * The version of the OpenAPI document: 71
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.checkout;
14

15
import java.util.Objects;
16
import java.util.Arrays;
17
import java.util.Map;
18
import java.util.HashMap;
19
import com.fasterxml.jackson.annotation.JsonInclude;
20
import com.fasterxml.jackson.annotation.JsonProperty;
21
import com.fasterxml.jackson.annotation.JsonCreator;
22
import com.fasterxml.jackson.annotation.JsonTypeName;
23
import com.fasterxml.jackson.annotation.JsonValue;
24
import io.swagger.annotations.ApiModel;
25
import io.swagger.annotations.ApiModelProperty;
26
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
27
import com.fasterxml.jackson.core.JsonProcessingException;
28

29

30
/**
31
 * DragonpayDetails
32
 */
33
@JsonPropertyOrder({
34
  DragonpayDetails.JSON_PROPERTY_CHECKOUT_ATTEMPT_ID,
35
  DragonpayDetails.JSON_PROPERTY_ISSUER,
36
  DragonpayDetails.JSON_PROPERTY_SHOPPER_EMAIL,
37
  DragonpayDetails.JSON_PROPERTY_SUBTYPE,
38
  DragonpayDetails.JSON_PROPERTY_TYPE
39
})
40

41
public class DragonpayDetails {
42
  public static final String JSON_PROPERTY_CHECKOUT_ATTEMPT_ID = "checkoutAttemptId";
43
  private String checkoutAttemptId;
44

45
  public static final String JSON_PROPERTY_ISSUER = "issuer";
46
  private String issuer;
47

48
  public static final String JSON_PROPERTY_SHOPPER_EMAIL = "shopperEmail";
49
  private String shopperEmail;
50

51
  public static final String JSON_PROPERTY_SUBTYPE = "subtype";
52
  private String subtype;
53

54
  /**
55
   * **dragonpay**
56
   */
57
  public enum TypeEnum {
1✔
58
    EBANKING("dragonpay_ebanking"),
1✔
59
    
60
    OTC_BANKING("dragonpay_otc_banking"),
1✔
61
    
62
    OTC_NON_BANKING("dragonpay_otc_non_banking"),
1✔
63
    
64
    OTC_PHILIPPINES("dragonpay_otc_philippines");
1✔
65

66
    private String value;
67

68
    TypeEnum(String value) {
1✔
69
      this.value = value;
1✔
70
    }
1✔
71

72
    @JsonValue
73
    public String getValue() {
74
      return value;
1✔
75
    }
76

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

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

93
  public static final String JSON_PROPERTY_TYPE = "type";
94
  private TypeEnum type;
95

96
  public DragonpayDetails() { 
1✔
97
  }
1✔
98

99
  public DragonpayDetails checkoutAttemptId(String checkoutAttemptId) {
100
    this.checkoutAttemptId = checkoutAttemptId;
×
101
    return this;
×
102
  }
103

104
   /**
105
   * The checkout attempt identifier.
106
   * @return checkoutAttemptId
107
  **/
108
  @ApiModelProperty(value = "The checkout attempt identifier.")
109
  @JsonProperty(JSON_PROPERTY_CHECKOUT_ATTEMPT_ID)
110
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
111

112
  public String getCheckoutAttemptId() {
113
    return checkoutAttemptId;
×
114
  }
115

116

117
 /**
118
  * The checkout attempt identifier.
119
  *
120
  * @param checkoutAttemptId
121
  */ 
122
  @JsonProperty(JSON_PROPERTY_CHECKOUT_ATTEMPT_ID)
123
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
124
  public void setCheckoutAttemptId(String checkoutAttemptId) {
125
    this.checkoutAttemptId = checkoutAttemptId;
×
126
  }
×
127

128

129
  public DragonpayDetails issuer(String issuer) {
130
    this.issuer = issuer;
×
131
    return this;
×
132
  }
133

134
   /**
135
   * The Dragonpay issuer value of the shopper's selected bank. Set this to an **id** of a Dragonpay issuer to preselect it.
136
   * @return issuer
137
  **/
138
  @ApiModelProperty(required = true, value = "The Dragonpay issuer value of the shopper's selected bank. Set this to an **id** of a Dragonpay issuer to preselect it.")
139
  @JsonProperty(JSON_PROPERTY_ISSUER)
140
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
141

142
  public String getIssuer() {
143
    return issuer;
×
144
  }
145

146

147
 /**
148
  * The Dragonpay issuer value of the shopper's selected bank. Set this to an **id** of a Dragonpay issuer to preselect it.
149
  *
150
  * @param issuer
151
  */ 
152
  @JsonProperty(JSON_PROPERTY_ISSUER)
153
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
154
  public void setIssuer(String issuer) {
155
    this.issuer = issuer;
1✔
156
  }
1✔
157

158

159
  public DragonpayDetails shopperEmail(String shopperEmail) {
160
    this.shopperEmail = shopperEmail;
×
161
    return this;
×
162
  }
163

164
   /**
165
   * The shopper’s email address.
166
   * @return shopperEmail
167
  **/
168
  @ApiModelProperty(value = "The shopper’s email address.")
169
  @JsonProperty(JSON_PROPERTY_SHOPPER_EMAIL)
170
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
171

172
  public String getShopperEmail() {
173
    return shopperEmail;
×
174
  }
175

176

177
 /**
178
  * The shopper’s email address.
179
  *
180
  * @param shopperEmail
181
  */ 
182
  @JsonProperty(JSON_PROPERTY_SHOPPER_EMAIL)
183
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
184
  public void setShopperEmail(String shopperEmail) {
185
    this.shopperEmail = shopperEmail;
×
186
  }
×
187

188

189
  public DragonpayDetails subtype(String subtype) {
NEW
190
    this.subtype = subtype;
×
NEW
191
    return this;
×
192
  }
193

194
   /**
195
   * The payment method subtype.
196
   * @return subtype
197
  **/
198
  @ApiModelProperty(value = "The payment method subtype.")
199
  @JsonProperty(JSON_PROPERTY_SUBTYPE)
200
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
201

202
  public String getSubtype() {
NEW
203
    return subtype;
×
204
  }
205

206

207
 /**
208
  * The payment method subtype.
209
  *
210
  * @param subtype
211
  */ 
212
  @JsonProperty(JSON_PROPERTY_SUBTYPE)
213
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
214
  public void setSubtype(String subtype) {
NEW
215
    this.subtype = subtype;
×
NEW
216
  }
×
217

218

219
  public DragonpayDetails type(TypeEnum type) {
220
    this.type = type;
×
221
    return this;
×
222
  }
223

224
   /**
225
   * **dragonpay**
226
   * @return type
227
  **/
228
  @ApiModelProperty(required = true, value = "**dragonpay**")
229
  @JsonProperty(JSON_PROPERTY_TYPE)
230
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
231

232
  public TypeEnum getType() {
233
    return type;
×
234
  }
235

236

237
 /**
238
  * **dragonpay**
239
  *
240
  * @param type
241
  */ 
242
  @JsonProperty(JSON_PROPERTY_TYPE)
243
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
244
  public void setType(TypeEnum type) {
245
    this.type = type;
×
246
  }
×
247

248

249
  /**
250
   * Return true if this DragonpayDetails object is equal to o.
251
   */
252
  @Override
253
  public boolean equals(Object o) {
254
    if (this == o) {
×
255
      return true;
×
256
    }
257
    if (o == null || getClass() != o.getClass()) {
×
258
      return false;
×
259
    }
260
    DragonpayDetails dragonpayDetails = (DragonpayDetails) o;
×
261
    return Objects.equals(this.checkoutAttemptId, dragonpayDetails.checkoutAttemptId) &&
×
262
        Objects.equals(this.issuer, dragonpayDetails.issuer) &&
×
263
        Objects.equals(this.shopperEmail, dragonpayDetails.shopperEmail) &&
×
NEW
264
        Objects.equals(this.subtype, dragonpayDetails.subtype) &&
×
265
        Objects.equals(this.type, dragonpayDetails.type);
×
266
  }
267

268
  @Override
269
  public int hashCode() {
NEW
270
    return Objects.hash(checkoutAttemptId, issuer, shopperEmail, subtype, type);
×
271
  }
272

273
  @Override
274
  public String toString() {
275
    StringBuilder sb = new StringBuilder();
×
276
    sb.append("class DragonpayDetails {\n");
×
277
    sb.append("    checkoutAttemptId: ").append(toIndentedString(checkoutAttemptId)).append("\n");
×
278
    sb.append("    issuer: ").append(toIndentedString(issuer)).append("\n");
×
279
    sb.append("    shopperEmail: ").append(toIndentedString(shopperEmail)).append("\n");
×
NEW
280
    sb.append("    subtype: ").append(toIndentedString(subtype)).append("\n");
×
281
    sb.append("    type: ").append(toIndentedString(type)).append("\n");
×
282
    sb.append("}");
×
283
    return sb.toString();
×
284
  }
285

286
  /**
287
   * Convert the given object to string with each line indented by 4 spaces
288
   * (except the first line).
289
   */
290
  private String toIndentedString(Object o) {
291
    if (o == null) {
×
292
      return "null";
×
293
    }
294
    return o.toString().replace("\n", "\n    ");
×
295
  }
296

297
/**
298
   * Create an instance of DragonpayDetails given an JSON string
299
   *
300
   * @param jsonString JSON string
301
   * @return An instance of DragonpayDetails
302
   * @throws JsonProcessingException if the JSON string is invalid with respect to DragonpayDetails
303
   */
304
  public static DragonpayDetails fromJson(String jsonString) throws JsonProcessingException {
305
    return JSON.getMapper().readValue(jsonString, DragonpayDetails.class);
×
306
  }
307
/**
308
  * Convert an instance of DragonpayDetails to an JSON string
309
  *
310
  * @return JSON string
311
  */
312
  public String toJson() throws JsonProcessingException {
313
    return JSON.getMapper().writeValueAsString(this);
×
314
  }
315
}
316

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

© 2025 Coveralls, Inc