Skip to content

Commit eaacdb1

Browse files
committed
Fix.
1 parent 0ffef7f commit eaacdb1

2 files changed

Lines changed: 0 additions & 42 deletions

File tree

src/main/java/cl/throttr/responses/GetResponse.java

Lines changed: 0 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -31,44 +31,6 @@ public record GetResponse(
3131
long ttl,
3232
byte[] value
3333
) {
34-
/**
35-
* Equals
36-
*
37-
* @param o the reference object with which to compare.
38-
* @return
39-
*/
40-
@Override
41-
public boolean equals(Object o) {
42-
return this == o;
43-
}
44-
45-
/**
46-
* Hashcode
47-
*
48-
* @return
49-
*/
50-
@Override
51-
public int hashCode() {
52-
int result = java.util.Objects.hash(success, ttlType, ttl);
53-
result = 31 * result + java.util.Arrays.hashCode(value);
54-
return result;
55-
}
56-
57-
/**
58-
* To string
59-
*
60-
* @return
61-
*/
62-
@Override
63-
public String toString() {
64-
return "GetResponse{" +
65-
"success=" + success +
66-
", ttlType=" + ttlType +
67-
", ttl=" + ttl +
68-
", value=" + java.util.Arrays.toString(value) +
69-
'}';
70-
}
71-
7234
/**
7335
* Parse from bytes
7436
*

src/main/java/cl/throttr/responses/InfoResponse.java

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -136,10 +136,6 @@ public InfoResponse(
136136
}
137137

138138
public static InfoResponse fromBytes(byte[] full) {
139-
if (full.length != 433) {
140-
throw new IllegalArgumentException("Expected 433 bytes, got " + full.length);
141-
}
142-
143139
boolean success = full[0] == 0x01;
144140
ByteBuffer bb = ByteBuffer.wrap(full, 1, 432).order(ByteOrder.LITTLE_ENDIAN);
145141
long[] values = new long[52];

0 commit comments

Comments
 (0)