Skip to content

Commit 9d33c74

Browse files
AdyenAutomationBotjeandersonbc
authored andcommitted
[capital] Automated update from Adyen/adyen-openapi@0a007ce
1 parent 3b7be19 commit 9d33c74

52 files changed

Lines changed: 13899 additions & 0 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 310 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,310 @@
1+
/*
2+
* Capital API
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+
package com.adyen.model.capital;
13+
14+
import com.fasterxml.jackson.annotation.JsonAnyGetter;
15+
import com.fasterxml.jackson.annotation.JsonIgnore;
16+
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
17+
import com.fasterxml.jackson.annotation.JsonInclude;
18+
import com.fasterxml.jackson.annotation.JsonProperty;
19+
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
20+
import com.fasterxml.jackson.annotation.JsonTypeInfo;
21+
import com.fasterxml.jackson.core.JsonProcessingException;
22+
import java.util.*;
23+
24+
/** AULocalAccountIdentification */
25+
@JsonPropertyOrder({
26+
AULocalAccountIdentification.JSON_PROPERTY_ACCOUNT_NUMBER,
27+
AULocalAccountIdentification.JSON_PROPERTY_BSB_CODE,
28+
AULocalAccountIdentification.JSON_PROPERTY_TYPE
29+
})
30+
@JsonIgnoreProperties(
31+
value =
32+
"type", // ignore manually set type, it will be automatically generated by Jackson during
33+
// serialization
34+
allowSetters = true // allows the type to be set during deserialization
35+
)
36+
@JsonTypeInfo(
37+
use = JsonTypeInfo.Id.NAME,
38+
include = JsonTypeInfo.As.PROPERTY,
39+
property = "type",
40+
visible = true)
41+
public class AULocalAccountIdentification extends BankAccountIdentification {
42+
public static final String JSON_PROPERTY_ACCOUNT_NUMBER = "accountNumber";
43+
private String accountNumber;
44+
45+
/** Mark when the attribute has been explicitly set. */
46+
private boolean isSetAccountNumber = false;
47+
48+
public static final String JSON_PROPERTY_BSB_CODE = "bsbCode";
49+
private String bsbCode;
50+
51+
/** Mark when the attribute has been explicitly set. */
52+
private boolean isSetBsbCode = false;
53+
54+
public static final String JSON_PROPERTY_TYPE = "type";
55+
private String type;
56+
57+
/** Mark when the attribute has been explicitly set. */
58+
private boolean isSetType = false;
59+
60+
/**
61+
* Sets whether attributes with null values should be explicitly included in the JSON payload.
62+
* Default is false.
63+
*/
64+
@JsonIgnore private boolean includeNullValues = false;
65+
66+
public AULocalAccountIdentification() {}
67+
68+
/**
69+
* The bank account number, without separators or whitespace.
70+
*
71+
* @param accountNumber The bank account number, without separators or whitespace.
72+
* @return the current {@code AULocalAccountIdentification} instance, allowing for method chaining
73+
*/
74+
public AULocalAccountIdentification accountNumber(String accountNumber) {
75+
this.accountNumber = accountNumber;
76+
isSetAccountNumber = true; // mark as set
77+
return this;
78+
}
79+
80+
/**
81+
* The bank account number, without separators or whitespace.
82+
*
83+
* @return accountNumber The bank account number, without separators or whitespace.
84+
*/
85+
@JsonProperty(JSON_PROPERTY_ACCOUNT_NUMBER)
86+
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
87+
public String getAccountNumber() {
88+
return accountNumber;
89+
}
90+
91+
/**
92+
* The bank account number, without separators or whitespace.
93+
*
94+
* @param accountNumber The bank account number, without separators or whitespace.
95+
*/
96+
@JsonProperty(JSON_PROPERTY_ACCOUNT_NUMBER)
97+
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
98+
public void setAccountNumber(String accountNumber) {
99+
this.accountNumber = accountNumber;
100+
isSetAccountNumber = true; // mark as set
101+
}
102+
103+
/**
104+
* The 6-digit [Bank State Branch (BSB) code](https://en.wikipedia.org/wiki/Bank_state_branch),
105+
* without separators or whitespace.
106+
*
107+
* @param bsbCode The 6-digit [Bank State Branch (BSB)
108+
* code](https://en.wikipedia.org/wiki/Bank_state_branch), without separators or whitespace.
109+
* @return the current {@code AULocalAccountIdentification} instance, allowing for method chaining
110+
*/
111+
public AULocalAccountIdentification bsbCode(String bsbCode) {
112+
this.bsbCode = bsbCode;
113+
isSetBsbCode = true; // mark as set
114+
return this;
115+
}
116+
117+
/**
118+
* The 6-digit [Bank State Branch (BSB) code](https://en.wikipedia.org/wiki/Bank_state_branch),
119+
* without separators or whitespace.
120+
*
121+
* @return bsbCode The 6-digit [Bank State Branch (BSB)
122+
* code](https://en.wikipedia.org/wiki/Bank_state_branch), without separators or whitespace.
123+
*/
124+
@JsonProperty(JSON_PROPERTY_BSB_CODE)
125+
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
126+
public String getBsbCode() {
127+
return bsbCode;
128+
}
129+
130+
/**
131+
* The 6-digit [Bank State Branch (BSB) code](https://en.wikipedia.org/wiki/Bank_state_branch),
132+
* without separators or whitespace.
133+
*
134+
* @param bsbCode The 6-digit [Bank State Branch (BSB)
135+
* code](https://en.wikipedia.org/wiki/Bank_state_branch), without separators or whitespace.
136+
*/
137+
@JsonProperty(JSON_PROPERTY_BSB_CODE)
138+
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
139+
public void setBsbCode(String bsbCode) {
140+
this.bsbCode = bsbCode;
141+
isSetBsbCode = true; // mark as set
142+
}
143+
144+
/**
145+
* **auLocal**
146+
*
147+
* @param type **auLocal**
148+
* @return the current {@code AULocalAccountIdentification} instance, allowing for method chaining
149+
*/
150+
public AULocalAccountIdentification type(String type) {
151+
this.type = type;
152+
isSetType = true; // mark as set
153+
return this;
154+
}
155+
156+
/**
157+
* **auLocal**
158+
*
159+
* @return type **auLocal**
160+
*/
161+
@JsonProperty(JSON_PROPERTY_TYPE)
162+
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
163+
public String getType() {
164+
return type;
165+
}
166+
167+
/**
168+
* **auLocal**
169+
*
170+
* @param type **auLocal**
171+
*/
172+
@JsonProperty(JSON_PROPERTY_TYPE)
173+
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
174+
public void setType(String type) {
175+
this.type = type;
176+
isSetType = true; // mark as set
177+
}
178+
179+
/**
180+
* Configures whether null values are explicitly serialized in the JSON payload. Default is false.
181+
*/
182+
public AULocalAccountIdentification includeNullValues(boolean includeNullValues) {
183+
this.includeNullValues = includeNullValues;
184+
return this;
185+
}
186+
187+
/** Returns whether null values are explicitly serialized in the JSON payload. */
188+
public boolean isIncludeNullValues() {
189+
return includeNullValues;
190+
}
191+
192+
/**
193+
* Sets whether null values should be explicitly serialized in the JSON payload. Default is false.
194+
*/
195+
public void setIncludeNullValues(boolean includeNullValues) {
196+
this.includeNullValues = includeNullValues;
197+
}
198+
199+
/** Return true if this AULocalAccountIdentification object is equal to o. */
200+
@Override
201+
public boolean equals(Object o) {
202+
if (this == o) {
203+
return true;
204+
}
205+
if (o == null || getClass() != o.getClass()) {
206+
return false;
207+
}
208+
AULocalAccountIdentification auLocalAccountIdentification = (AULocalAccountIdentification) o;
209+
return Objects.equals(this.accountNumber, auLocalAccountIdentification.accountNumber)
210+
&& Objects.equals(this.isSetAccountNumber, auLocalAccountIdentification.isSetAccountNumber)
211+
&& Objects.equals(this.bsbCode, auLocalAccountIdentification.bsbCode)
212+
&& Objects.equals(this.isSetBsbCode, auLocalAccountIdentification.isSetBsbCode)
213+
&& Objects.equals(this.type, auLocalAccountIdentification.type)
214+
&& Objects.equals(this.isSetType, auLocalAccountIdentification.isSetType)
215+
&& super.equals(o);
216+
}
217+
218+
@Override
219+
public int hashCode() {
220+
return Objects.hash(
221+
accountNumber,
222+
isSetAccountNumber,
223+
bsbCode,
224+
isSetBsbCode,
225+
type,
226+
isSetType,
227+
super.hashCode());
228+
}
229+
230+
@Override
231+
public String toString() {
232+
StringBuilder sb = new StringBuilder();
233+
sb.append("class AULocalAccountIdentification {\n");
234+
sb.append(" ").append(toIndentedString(super.toString())).append("\n");
235+
sb.append(" accountNumber: ").append(toIndentedString(accountNumber)).append("\n");
236+
sb.append(" bsbCode: ").append(toIndentedString(bsbCode)).append("\n");
237+
sb.append(" type: ").append(toIndentedString(type)).append("\n");
238+
sb.append("}");
239+
return sb.toString();
240+
}
241+
242+
/**
243+
* Convert the given object to string with each line indented by 4 spaces (except the first line).
244+
*/
245+
private String toIndentedString(Object o) {
246+
if (o == null) {
247+
return "null";
248+
}
249+
return o.toString().replace("\n", "\n ");
250+
}
251+
252+
static {
253+
// Initialize and register the discriminator mappings.
254+
Map<String, Class<?>> mappings = new HashMap<>();
255+
mappings.put("AULocalAccountIdentification", AULocalAccountIdentification.class);
256+
JSON.registerDiscriminator(AULocalAccountIdentification.class, "type", mappings);
257+
}
258+
259+
/** Returns a map of properties to be merged into the JSON payload as explicit null values. */
260+
@JsonInclude(JsonInclude.Include.ALWAYS)
261+
@JsonAnyGetter
262+
public Map<String, Object> getExplicitNulls() {
263+
if (!this.includeNullValues) {
264+
return Collections.emptyMap();
265+
}
266+
267+
Map<String, Object> nulls = new HashMap<>();
268+
269+
if (isSetAccountNumber) {
270+
addIfNull(nulls, JSON_PROPERTY_ACCOUNT_NUMBER, this.accountNumber);
271+
}
272+
if (isSetBsbCode) {
273+
addIfNull(nulls, JSON_PROPERTY_BSB_CODE, this.bsbCode);
274+
}
275+
if (isSetType) {
276+
addIfNull(nulls, JSON_PROPERTY_TYPE, this.type);
277+
}
278+
279+
return nulls;
280+
}
281+
282+
// add to map when value is null
283+
private void addIfNull(Map<String, Object> map, String key, Object value) {
284+
if (value == null) {
285+
map.put(key, null);
286+
}
287+
}
288+
289+
/**
290+
* Create an instance of AULocalAccountIdentification given an JSON string
291+
*
292+
* @param jsonString JSON string
293+
* @return An instance of AULocalAccountIdentification
294+
* @throws JsonProcessingException if the JSON string is invalid with respect to
295+
* AULocalAccountIdentification
296+
*/
297+
public static AULocalAccountIdentification fromJson(String jsonString)
298+
throws JsonProcessingException {
299+
return JSON.getMapper().readValue(jsonString, AULocalAccountIdentification.class);
300+
}
301+
302+
/**
303+
* Convert an instance of AULocalAccountIdentification to an JSON string
304+
*
305+
* @return JSON string
306+
*/
307+
public String toJson() throws JsonProcessingException {
308+
return JSON.getMapper().writeValueAsString(this);
309+
}
310+
}

0 commit comments

Comments
 (0)