@InterfaceAudience.Public @InterfaceStability.Stable public abstract class ByteArrayComparable extends Object implements Comparable<byte[]>
| Constructor and Description |
|---|
ByteArrayComparable(byte[] value)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(byte[] value) |
abstract int |
compareTo(byte[] value,
int offset,
int length)
Special compareTo method for subclasses, to avoid
copying byte[] unnecessarily.
|
byte[] |
getValue() |
static ByteArrayComparable |
parseFrom(byte[] pbBytes) |
abstract byte[] |
toByteArray() |
public ByteArrayComparable(byte[] value)
value - the value to compare againstpublic byte[] getValue()
public abstract byte[] toByteArray()
public static ByteArrayComparable parseFrom(byte[] pbBytes) throws DeserializationException
pbBytes - A pb serialized ByteArrayComparable instanceByteArrayComparable made from bytesDeserializationExceptiontoByteArray()public int compareTo(byte[] value)
compareTo in interface Comparable<byte[]>public abstract int compareTo(byte[] value,
int offset,
int length)
value - byte[] to compareoffset - offset into valuelength - number of bytes to compareCopyright © 2007–2019 The Apache Software Foundation. All rights reserved.