| Modifier and Type | Field and Description |
|---|---|
static int |
BITOFBYTE
The Constant BIT OF A BYTE.
|
protected byte |
typ
The Byte Typ.
|
static int |
TYPBYTE |
protected byte[] |
values
The values.
|
| Constructor and Description |
|---|
ByteEntity() |
| Modifier and Type | Method and Description |
|---|---|
byte |
byteToUnsignedByte(int n)
Byte to unsigned byte.
|
int |
calcLength(boolean isDynamic,
boolean isLast)
calculate the length of value
|
static ByteEntity |
create(java.lang.Object value) |
BufferedBytes |
getBytes(boolean isDynamic) |
BaseItem |
getNewList(boolean keyValue) |
byte |
getTyp()
Gets the typ.
|
byte[] |
getValue()
Gets the value.
|
java.lang.Object |
getValueItem(java.lang.Object key) |
boolean |
isEmpty() |
boolean |
setValues(java.lang.Object value) |
int |
size() |
java.lang.String |
toString() |
java.lang.String |
toString(ByteConverter converter)
Convert the bytes to a String
|
java.lang.String |
toString(ByteConverter converter,
boolean dynamic)
Convert the bytes to a String
|
BaseItem |
withAll(java.lang.Object... values) |
ByteEntity |
withValue(byte typ,
byte value)
Sets the value.
|
ByteEntity |
withValue(byte typ,
byte[] value)
Sets the value.
|
ByteEntity |
withValue(byte typ,
int value) |
void |
writeBytes(BufferedBytes buffer,
boolean isDynamic,
boolean isLast,
boolean isPrimitive)
Gets the bytes.
|
public static final int BITOFBYTE
public static final int TYPBYTE
protected byte typ
protected byte[] values
public byte[] getValue()
public ByteEntity withValue(byte typ, byte[] value)
typ - the new Typvalue - the new valuepublic ByteEntity withValue(byte typ, byte value)
typ - The Typ of Elementvalue - the new valuepublic ByteEntity withValue(byte typ, int value)
public byte byteToUnsignedByte(int n)
n - the Bytepublic java.lang.String toString()
public java.lang.String toString(ByteConverter converter)
public java.lang.String toString(ByteConverter converter, boolean dynamic)
public void writeBytes(BufferedBytes buffer, boolean isDynamic, boolean isLast, boolean isPrimitive)
writeBytes in interface ByteItembuffer - The Buffer to writeisDynamic - is short the Stream for messageisLast - is the Element is the last of GroupisPrimitive - is the Element is the StreamClazzpublic BufferedBytes getBytes(boolean isDynamic)
public boolean setValues(java.lang.Object value)
public byte getTyp()
public int calcLength(boolean isDynamic,
boolean isLast)
calcLength in interface ByteItemisDynamic - ByteStream for minimize outputisLast - is the Element is the Last of Grouppublic BaseItem getNewList(boolean keyValue)
getNewList in interface BaseItempublic boolean isEmpty()
public static ByteEntity create(java.lang.Object value)
public BaseItem withAll(java.lang.Object... values)
public java.lang.Object getValueItem(java.lang.Object key)
getValueItem in interface BaseItem