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

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

22 Sep 2023 11:24AM UTC coverage: 12.611%. First build
#2661

push

web-flow
Merge 251f6ff51 into 9e36e9c01

9262 of 9262 new or added lines in 142 files covered. (100.0%)

11033 of 87486 relevant lines covered (12.61%)

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/marketpayfund/TransferFundsResponse.java
1
/*
2
 * Fund API
3
 * This API is used for the classic integration. If you are just starting your implementation, refer to our [new integration guide](https://docs.adyen.com/marketplaces-and-platforms) instead.  The Fund API provides endpoints for managing the funds in the accounts on your platform. These management operations include, for example, the transfer of funds from one account to another, the payout of funds to an account holder, and the retrieval of balances in an account.  For more information, refer to our [documentation](https://docs.adyen.com/marketplaces-and-platforms/classic/). ## Authentication Your Adyen contact will provide your API credential and an API key. To connect to the API, add an `X-API-Key` header with the API key as the value, for example:   ``` curl -H \"Content-Type: application/json\" \\ -H \"X-API-Key: YOUR_API_KEY\" \\ ... ```  Alternatively, you can use the username and password to connect to the API using basic authentication. For example:  ``` curl -U \"ws@MarketPlace.YOUR_PLATFORM_ACCOUNT\":\"YOUR_WS_PASSWORD\" \\ -H \"Content-Type: application/json\" \\ ... ``` When going live, you need to generate new web service user credentials to access the [live endpoints](https://docs.adyen.com/development-resources/live-endpoints).  ## Versioning The Fund API supports [versioning](https://docs.adyen.com/development-resources/versioning) using a version suffix in the endpoint URL. This suffix has the following format: \"vXX\", where XX is the version number.  For example: ``` https://cal-test.adyen.com/cal/services/Fund/v6/accountHolderBalance ```
4
 *
5
 * The version of the OpenAPI document: 6
6
 * 
7
 *
8
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
 * https://openapi-generator.tech
10
 * Do not edit the class manually.
11
 */
12

13

14
package com.adyen.model.marketpayfund;
15

16
import java.util.Objects;
17
import java.util.Arrays;
18
import java.util.Map;
19
import java.util.HashMap;
20
import com.adyen.model.marketpayfund.ErrorFieldType;
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
 * TransferFundsResponse
36
 */
37
@JsonPropertyOrder({
38
  TransferFundsResponse.JSON_PROPERTY_INVALID_FIELDS,
39
  TransferFundsResponse.JSON_PROPERTY_MERCHANT_REFERENCE,
40
  TransferFundsResponse.JSON_PROPERTY_PSP_REFERENCE,
41
  TransferFundsResponse.JSON_PROPERTY_RESULT_CODE
42
})
43

44
public class TransferFundsResponse {
45
  public static final String JSON_PROPERTY_INVALID_FIELDS = "invalidFields";
46
  private List<ErrorFieldType> invalidFields = null;
×
47

48
  public static final String JSON_PROPERTY_MERCHANT_REFERENCE = "merchantReference";
49
  private String merchantReference;
50

51
  public static final String JSON_PROPERTY_PSP_REFERENCE = "pspReference";
52
  private String pspReference;
53

54
  public static final String JSON_PROPERTY_RESULT_CODE = "resultCode";
55
  private String resultCode;
56

57
  public TransferFundsResponse() { 
×
58
  }
×
59

60
  public TransferFundsResponse invalidFields(List<ErrorFieldType> invalidFields) {
61
    this.invalidFields = invalidFields;
×
62
    return this;
×
63
  }
64

65
  public TransferFundsResponse addInvalidFieldsItem(ErrorFieldType invalidFieldsItem) {
66
    if (this.invalidFields == null) {
×
67
      this.invalidFields = new ArrayList<>();
×
68
    }
69
    this.invalidFields.add(invalidFieldsItem);
×
70
    return this;
×
71
  }
72

73
   /**
74
   * Contains field validation errors that would prevent requests from being processed.
75
   * @return invalidFields
76
  **/
77
  @ApiModelProperty(value = "Contains field validation errors that would prevent requests from being processed.")
78
  @JsonProperty(JSON_PROPERTY_INVALID_FIELDS)
79
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
80

81
  public List<ErrorFieldType> getInvalidFields() {
82
    return invalidFields;
×
83
  }
84

85

86
  @JsonProperty(JSON_PROPERTY_INVALID_FIELDS)
87
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
88
  public void setInvalidFields(List<ErrorFieldType> invalidFields) {
89
    this.invalidFields = invalidFields;
×
90
  }
×
91

92

93
  public TransferFundsResponse merchantReference(String merchantReference) {
94
    this.merchantReference = merchantReference;
×
95
    return this;
×
96
  }
97

98
   /**
99
   * The value supplied by the executing user when initiating the transfer; may be used to link multiple transactions.
100
   * @return merchantReference
101
  **/
102
  @ApiModelProperty(value = "The value supplied by the executing user when initiating the transfer; may be used to link multiple transactions.")
103
  @JsonProperty(JSON_PROPERTY_MERCHANT_REFERENCE)
104
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
105

106
  public String getMerchantReference() {
107
    return merchantReference;
×
108
  }
109

110

111
  @JsonProperty(JSON_PROPERTY_MERCHANT_REFERENCE)
112
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
113
  public void setMerchantReference(String merchantReference) {
114
    this.merchantReference = merchantReference;
×
115
  }
×
116

117

118
  public TransferFundsResponse pspReference(String pspReference) {
119
    this.pspReference = pspReference;
×
120
    return this;
×
121
  }
122

123
   /**
124
   * The reference of a request. Can be used to uniquely identify the request.
125
   * @return pspReference
126
  **/
127
  @ApiModelProperty(value = "The reference of a request. Can be used to uniquely identify the request.")
128
  @JsonProperty(JSON_PROPERTY_PSP_REFERENCE)
129
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
130

131
  public String getPspReference() {
132
    return pspReference;
×
133
  }
134

135

136
  @JsonProperty(JSON_PROPERTY_PSP_REFERENCE)
137
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
138
  public void setPspReference(String pspReference) {
139
    this.pspReference = pspReference;
×
140
  }
×
141

142

143
  public TransferFundsResponse resultCode(String resultCode) {
144
    this.resultCode = resultCode;
×
145
    return this;
×
146
  }
147

148
   /**
149
   * The result code.
150
   * @return resultCode
151
  **/
152
  @ApiModelProperty(value = "The result code.")
153
  @JsonProperty(JSON_PROPERTY_RESULT_CODE)
154
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
155

156
  public String getResultCode() {
157
    return resultCode;
×
158
  }
159

160

161
  @JsonProperty(JSON_PROPERTY_RESULT_CODE)
162
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
163
  public void setResultCode(String resultCode) {
164
    this.resultCode = resultCode;
×
165
  }
×
166

167

168
  /**
169
   * Return true if this TransferFundsResponse object is equal to o.
170
   */
171
  @Override
172
  public boolean equals(Object o) {
173
    if (this == o) {
×
174
      return true;
×
175
    }
176
    if (o == null || getClass() != o.getClass()) {
×
177
      return false;
×
178
    }
179
    TransferFundsResponse transferFundsResponse = (TransferFundsResponse) o;
×
180
    return Objects.equals(this.invalidFields, transferFundsResponse.invalidFields) &&
×
181
        Objects.equals(this.merchantReference, transferFundsResponse.merchantReference) &&
×
182
        Objects.equals(this.pspReference, transferFundsResponse.pspReference) &&
×
183
        Objects.equals(this.resultCode, transferFundsResponse.resultCode);
×
184
  }
185

186
  @Override
187
  public int hashCode() {
188
    return Objects.hash(invalidFields, merchantReference, pspReference, resultCode);
×
189
  }
190

191
  @Override
192
  public String toString() {
193
    StringBuilder sb = new StringBuilder();
×
194
    sb.append("class TransferFundsResponse {\n");
×
195
    sb.append("    invalidFields: ").append(toIndentedString(invalidFields)).append("\n");
×
196
    sb.append("    merchantReference: ").append(toIndentedString(merchantReference)).append("\n");
×
197
    sb.append("    pspReference: ").append(toIndentedString(pspReference)).append("\n");
×
198
    sb.append("    resultCode: ").append(toIndentedString(resultCode)).append("\n");
×
199
    sb.append("}");
×
200
    return sb.toString();
×
201
  }
202

203
  /**
204
   * Convert the given object to string with each line indented by 4 spaces
205
   * (except the first line).
206
   */
207
  private String toIndentedString(Object o) {
208
    if (o == null) {
×
209
      return "null";
×
210
    }
211
    return o.toString().replace("\n", "\n    ");
×
212
  }
213

214
/**
215
   * Create an instance of TransferFundsResponse given an JSON string
216
   *
217
   * @param jsonString JSON string
218
   * @return An instance of TransferFundsResponse
219
   * @throws JsonProcessingException if the JSON string is invalid with respect to TransferFundsResponse
220
   */
221
  public static TransferFundsResponse fromJson(String jsonString) throws JsonProcessingException {
222
    return JSON.getMapper().readValue(jsonString, TransferFundsResponse.class);
×
223
  }
224
/**
225
  * Convert an instance of TransferFundsResponse to an JSON string
226
  *
227
  * @return JSON string
228
  */
229
  public String toJson() throws JsonProcessingException {
230
    return JSON.getMapper().writeValueAsString(this);
×
231
  }
232
}
233

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