public abstract class AbstractData<T> extends Object implements Data<T>
Data's equals(), hashCode() and
toString(). They should be default implementations in the Data interface itself,
but Java 8 doesn't allow to override Object's methods by default implementations
in interfaces.| Modifier | Constructor and Description |
|---|---|
protected |
AbstractData()
Constructor for use by subclasses.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj)
Compares
Datas' bytes representations. |
int |
hashCode()
Computes value's hash code by applying a hash function to
Data's bytes
representation. |
String |
toString()
Delegates to
Data's object toString(). |
clone, finalize, getClass, notify, notifyAll, wait, wait, waitbytes, bytesEquivalent, dataEquals, dataHashCode, dataToString, equivalent, get, getUsing, hash, offset, size, writeTopublic int hashCode()
Data's bytes
representation.hashCode in class ObjectData.dataHashCode().public boolean equals(Object obj)
Datas' bytes representations.equals in class ObjectData.dataEquals(Object).public String toString()
Data's object toString(). If deserialization fails with
exception (e. g. if data bytes are corrupted, and represent not a valid serialized form of
an object), traces the data's bytes and the exception.toString in class ObjectData.dataToString().Copyright © 2019. All rights reserved.