|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.geworkbench.util.BinaryEncodeDecode
public class BinaryEncodeDecode
Title: Binary Encoder Decoder
Description: The class has several method for encoding decoding ints into bytes
Copyright: Copyright (c) 2004
Company:
| Field Summary | |
|---|---|
static int |
MASK
|
static int |
SIZE_OF_INT
|
| Constructor Summary | |
|---|---|
BinaryEncodeDecode()
|
|
| Method Summary | |
|---|---|
static int |
decodeUnsignedInt32(byte[] bytes,
int offset)
|
static int[] |
decodeUnsignedInt32(byte[] array,
int offset,
int length)
Decode byte array into an int arrray |
static void |
encodeUnsignedInt32(byte[] array,
int index,
int value)
Encodes a int into a byte array starting at index. |
static byte[] |
encodeUnsignedInt32(int[] value)
Encode an int array into a byte array |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int SIZE_OF_INT
public static final int MASK
| Constructor Detail |
|---|
public BinaryEncodeDecode()
| Method Detail |
|---|
public static void encodeUnsignedInt32(byte[] array,
int index,
int value)
array - byte[]index - the index to start encoding
#param value the int to encodepublic static byte[] encodeUnsignedInt32(int[] value)
value - int[] the values to encode
public static int[] decodeUnsignedInt32(byte[] array,
int offset,
int length)
array - byte[] array to decdeoffset - int begining of decodinglength - int number of ints(!) to decode
public static int decodeUnsignedInt32(byte[] bytes,
int offset)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||