public class Signature extends SimpleDataStructure
Modifier and Type | Field and Description |
---|---|
static byte[] |
FAKE_SIGNATURE
Deprecated.
to be removed
|
static int |
SIGNATURE_BYTES
40
|
_data
Constructor and Description |
---|
Signature() |
Signature(byte[] data) |
Signature(SigType type)
Unknown type not allowed as we won't know the length to read in the data.
|
Signature(SigType type,
byte[] data)
Should we allow an unknown type here?
|
Modifier and Type | Method and Description |
---|---|
SigType |
getType() |
int |
length()
The legal length of the byte array in this data structure
|
String |
toString() |
calculateHash, equals, fromBase64, fromByteArray, getData, hashCode, readBytes, setData, toBase64, toByteArray, writeBytes
read
public static final int SIGNATURE_BYTES
public static final byte[] FAKE_SIGNATURE
public Signature()
public Signature(SigType type)
type
- non-nullpublic Signature(byte[] data)
public Signature(SigType type, byte[] data)
type
- non-nullpublic int length()
SimpleDataStructure
length
in class SimpleDataStructure
public SigType getType()
public String toString()
toString
in class SimpleDataStructure