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

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

08 Nov 2023 09:16AM CUT coverage: 12.837%. First build
#2829

push

web-flow
Merge 828273160 into b96088175

114 of 864 new or added lines in 50 files covered. (13.19%)

12393 of 96543 relevant lines covered (12.84%)

0.13 hits per line

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

21.05
/src/main/java/com/adyen/model/transactionwebhooks/ResourceReference.java
1
/*
2
 * Transaction webhooks
3
 *
4
 * The version of the OpenAPI document: 4
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.transactionwebhooks;
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
 * ResourceReference
32
 */
33
@JsonPropertyOrder({
34
  ResourceReference.JSON_PROPERTY_DESCRIPTION,
35
  ResourceReference.JSON_PROPERTY_ID,
36
  ResourceReference.JSON_PROPERTY_REFERENCE
37
})
38

39
public class ResourceReference {
40
  public static final String JSON_PROPERTY_DESCRIPTION = "description";
41
  private String description;
42

43
  public static final String JSON_PROPERTY_ID = "id";
44
  private String id;
45

46
  public static final String JSON_PROPERTY_REFERENCE = "reference";
47
  private String reference;
48

49
  public ResourceReference() { 
1✔
50
  }
1✔
51

52
  public ResourceReference description(String description) {
NEW
53
    this.description = description;
×
NEW
54
    return this;
×
55
  }
56

57
   /**
58
   * The description of the resource.
59
   * @return description
60
  **/
61
  @ApiModelProperty(value = "The description of the resource.")
62
  @JsonProperty(JSON_PROPERTY_DESCRIPTION)
63
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
64

65
  public String getDescription() {
NEW
66
    return description;
×
67
  }
68

69

70
  @JsonProperty(JSON_PROPERTY_DESCRIPTION)
71
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
72
  public void setDescription(String description) {
73
    this.description = description;
1✔
74
  }
1✔
75

76

77
  public ResourceReference id(String id) {
NEW
78
    this.id = id;
×
NEW
79
    return this;
×
80
  }
81

82
   /**
83
   * The unique identifier of the resource.
84
   * @return id
85
  **/
86
  @ApiModelProperty(value = "The unique identifier of the resource.")
87
  @JsonProperty(JSON_PROPERTY_ID)
88
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
89

90
  public String getId() {
NEW
91
    return id;
×
92
  }
93

94

95
  @JsonProperty(JSON_PROPERTY_ID)
96
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
97
  public void setId(String id) {
98
    this.id = id;
1✔
99
  }
1✔
100

101

102
  public ResourceReference reference(String reference) {
NEW
103
    this.reference = reference;
×
NEW
104
    return this;
×
105
  }
106

107
   /**
108
   * The reference for the resource.
109
   * @return reference
110
  **/
111
  @ApiModelProperty(value = "The reference for the resource.")
112
  @JsonProperty(JSON_PROPERTY_REFERENCE)
113
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
114

115
  public String getReference() {
NEW
116
    return reference;
×
117
  }
118

119

120
  @JsonProperty(JSON_PROPERTY_REFERENCE)
121
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
122
  public void setReference(String reference) {
123
    this.reference = reference;
1✔
124
  }
1✔
125

126

127
  /**
128
   * Return true if this ResourceReference object is equal to o.
129
   */
130
  @Override
131
  public boolean equals(Object o) {
NEW
132
    if (this == o) {
×
NEW
133
      return true;
×
134
    }
NEW
135
    if (o == null || getClass() != o.getClass()) {
×
NEW
136
      return false;
×
137
    }
NEW
138
    ResourceReference resourceReference = (ResourceReference) o;
×
NEW
139
    return Objects.equals(this.description, resourceReference.description) &&
×
NEW
140
        Objects.equals(this.id, resourceReference.id) &&
×
NEW
141
        Objects.equals(this.reference, resourceReference.reference);
×
142
  }
143

144
  @Override
145
  public int hashCode() {
NEW
146
    return Objects.hash(description, id, reference);
×
147
  }
148

149
  @Override
150
  public String toString() {
NEW
151
    StringBuilder sb = new StringBuilder();
×
NEW
152
    sb.append("class ResourceReference {\n");
×
NEW
153
    sb.append("    description: ").append(toIndentedString(description)).append("\n");
×
NEW
154
    sb.append("    id: ").append(toIndentedString(id)).append("\n");
×
NEW
155
    sb.append("    reference: ").append(toIndentedString(reference)).append("\n");
×
NEW
156
    sb.append("}");
×
NEW
157
    return sb.toString();
×
158
  }
159

160
  /**
161
   * Convert the given object to string with each line indented by 4 spaces
162
   * (except the first line).
163
   */
164
  private String toIndentedString(Object o) {
NEW
165
    if (o == null) {
×
NEW
166
      return "null";
×
167
    }
NEW
168
    return o.toString().replace("\n", "\n    ");
×
169
  }
170

171
/**
172
   * Create an instance of ResourceReference given an JSON string
173
   *
174
   * @param jsonString JSON string
175
   * @return An instance of ResourceReference
176
   * @throws JsonProcessingException if the JSON string is invalid with respect to ResourceReference
177
   */
178
  public static ResourceReference fromJson(String jsonString) throws JsonProcessingException {
NEW
179
    return JSON.getMapper().readValue(jsonString, ResourceReference.class);
×
180
  }
181
/**
182
  * Convert an instance of ResourceReference to an JSON string
183
  *
184
  * @return JSON string
185
  */
186
  public String toJson() throws JsonProcessingException {
NEW
187
    return JSON.getMapper().writeValueAsString(this);
×
188
  }
189
}
190

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