-
Notifications
You must be signed in to change notification settings - Fork 9
/
IntegerAttributeContent.java
47 lines (36 loc) · 1.16 KB
/
IntegerAttributeContent.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
package com.czertainly.api.model.common.attribute.v2.content;
import io.swagger.v3.oas.annotations.media.Schema;
import java.util.Objects;
public class IntegerAttributeContent extends BaseAttributeContent<Integer> {
@Schema(description = "Integer attribute value", requiredMode = Schema.RequiredMode.REQUIRED)
private Integer data;
public IntegerAttributeContent() {
}
public IntegerAttributeContent(Integer data) {
this.data = data;
}
public IntegerAttributeContent(String reference, Integer data) {
super(reference);
this.data = data;
}
@Override
public Integer getData() {
return data;
}
@Override
public void setData(Integer data) {
this.data = data;
}
@Override
public boolean equals(Object o) {
if (this == o) return true;
if (!(o instanceof IntegerAttributeContent)) return false;
if (!super.equals(o)) return false;
IntegerAttributeContent that = (IntegerAttributeContent) o;
return Objects.equals(data, that.data);
}
@Override
public int hashCode() {
return Objects.hash(super.hashCode(), data);
}
}