• 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

17.46
/src/main/java/com/adyen/model/checkout/GiropayDetails.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
 * GiropayDetails
32
 */
33
@JsonPropertyOrder({
34
  GiropayDetails.JSON_PROPERTY_CHECKOUT_ATTEMPT_ID,
35
  GiropayDetails.JSON_PROPERTY_RECURRING_DETAIL_REFERENCE,
36
  GiropayDetails.JSON_PROPERTY_STORED_PAYMENT_METHOD_ID,
37
  GiropayDetails.JSON_PROPERTY_SUBTYPE,
38
  GiropayDetails.JSON_PROPERTY_TYPE
39
})
40

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

45
  public static final String JSON_PROPERTY_RECURRING_DETAIL_REFERENCE = "recurringDetailReference";
46
  @Deprecated
47
  private String recurringDetailReference;
48

49
  public static final String JSON_PROPERTY_STORED_PAYMENT_METHOD_ID = "storedPaymentMethodId";
50
  private String storedPaymentMethodId;
51

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

55
  /**
56
   * **giropay**
57
   */
58
  public enum TypeEnum {
1✔
59
    GIROPAY("giropay");
1✔
60

61
    private String value;
62

63
    TypeEnum(String value) {
1✔
64
      this.value = value;
1✔
65
    }
1✔
66

67
    @JsonValue
68
    public String getValue() {
69
      return value;
1✔
70
    }
71

72
    @Override
73
    public String toString() {
74
      return String.valueOf(value);
×
75
    }
76

77
    @JsonCreator
78
    public static TypeEnum fromValue(String value) {
79
      for (TypeEnum b : TypeEnum.values()) {
1✔
80
        if (b.value.equals(value)) {
1✔
81
          return b;
×
82
        }
83
      }
84
      throw new IllegalArgumentException("Unexpected value '" + value + "'");
1✔
85
    }
86
  }
87

88
  public static final String JSON_PROPERTY_TYPE = "type";
89
  private TypeEnum type;
90

91
  public GiropayDetails() { 
1✔
92
  }
1✔
93

94
  public GiropayDetails checkoutAttemptId(String checkoutAttemptId) {
95
    this.checkoutAttemptId = checkoutAttemptId;
×
96
    return this;
×
97
  }
98

99
   /**
100
   * The checkout attempt identifier.
101
   * @return checkoutAttemptId
102
  **/
103
  @ApiModelProperty(value = "The checkout attempt identifier.")
104
  @JsonProperty(JSON_PROPERTY_CHECKOUT_ATTEMPT_ID)
105
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
106

107
  public String getCheckoutAttemptId() {
108
    return checkoutAttemptId;
×
109
  }
110

111

112
 /**
113
  * The checkout attempt identifier.
114
  *
115
  * @param checkoutAttemptId
116
  */ 
117
  @JsonProperty(JSON_PROPERTY_CHECKOUT_ATTEMPT_ID)
118
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
119
  public void setCheckoutAttemptId(String checkoutAttemptId) {
120
    this.checkoutAttemptId = checkoutAttemptId;
×
121
  }
×
122

123

124
  @Deprecated
125
  public GiropayDetails recurringDetailReference(String recurringDetailReference) {
126
    this.recurringDetailReference = recurringDetailReference;
×
127
    return this;
×
128
  }
129

130
   /**
131
   * This is the `recurringDetailReference` returned in the response when you created the token.
132
   * @return recurringDetailReference
133
   * @deprecated
134
  **/
135
  @Deprecated
136
  @ApiModelProperty(value = "This is the `recurringDetailReference` returned in the response when you created the token.")
137
  @JsonProperty(JSON_PROPERTY_RECURRING_DETAIL_REFERENCE)
138
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
139

140
  public String getRecurringDetailReference() {
141
    return recurringDetailReference;
×
142
  }
143

144

145
 /**
146
  * This is the `recurringDetailReference` returned in the response when you created the token.
147
  *
148
  * @param recurringDetailReference
149
  */ 
150
  @Deprecated
151
  @JsonProperty(JSON_PROPERTY_RECURRING_DETAIL_REFERENCE)
152
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
153
  public void setRecurringDetailReference(String recurringDetailReference) {
154
    this.recurringDetailReference = recurringDetailReference;
×
155
  }
×
156

157

158
  public GiropayDetails storedPaymentMethodId(String storedPaymentMethodId) {
159
    this.storedPaymentMethodId = storedPaymentMethodId;
×
160
    return this;
×
161
  }
162

163
   /**
164
   * This is the `recurringDetailReference` returned in the response when you created the token.
165
   * @return storedPaymentMethodId
166
  **/
167
  @ApiModelProperty(value = "This is the `recurringDetailReference` returned in the response when you created the token.")
168
  @JsonProperty(JSON_PROPERTY_STORED_PAYMENT_METHOD_ID)
169
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
170

171
  public String getStoredPaymentMethodId() {
172
    return storedPaymentMethodId;
×
173
  }
174

175

176
 /**
177
  * This is the `recurringDetailReference` returned in the response when you created the token.
178
  *
179
  * @param storedPaymentMethodId
180
  */ 
181
  @JsonProperty(JSON_PROPERTY_STORED_PAYMENT_METHOD_ID)
182
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
183
  public void setStoredPaymentMethodId(String storedPaymentMethodId) {
184
    this.storedPaymentMethodId = storedPaymentMethodId;
×
185
  }
×
186

187

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

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

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

205

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

217

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

223
   /**
224
   * **giropay**
225
   * @return type
226
  **/
227
  @ApiModelProperty(value = "**giropay**")
228
  @JsonProperty(JSON_PROPERTY_TYPE)
229
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
230

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

235

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

247

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

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

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

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

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

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