1 | public static long getValue(byte[] bytes) {↵ | | 1 | public static int getValue(byte[] bytes) {↵
|
2 | return getValue(bytes, 0);↵ | | 2 | return getValue(bytes, 0);↵
|
3 | }↵ | | 3 | }↵
|
|
4 | /**↵ | | 4 | /**↵
|
5 | * Override to make two instances with same value equal.↵ | | 5 | * Override to make two instances with same value equal.↵
|
6 | * @param o an object to compare↵ | | 6 | * @param o an object to compare↵
|
7 | * @return true if the objects are equal↵ | | 7 | * @return true if the objects are equal↵
|
8 | * @since 1.1↵ | | 8 | * @since 1.1↵
|
9 | */↵ | | 9 | */↵
|
10 | public boolean equals(Object o) {↵ | | 10 | public boolean equals(Object o) {↵
|
11 | if (o == null || !(o instanceof ZipLong)) {↵ | | 11 | if (o == null || !(o instanceof ZipShort)) {↵
|
12 | return false;↵ | | 12 | return false;↵
|
13 | }↵ | | 13 | }↵
|
14 | return value == ((ZipLong) o).getValue(); | | 14 | return value == ((ZipShort) o).getValue();
|