|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectde.bsvrz.sys.funclib.losb.util.ByteIO
public class ByteIO
Diese Klasse enthaelt die Funktionalitaet fuer das Handling von Ganzzahlen in Byte-Arrays.
| Field Summary | |
|---|---|
static int |
INT4B_LEN
Datentyp-Laenge in Byte. |
static int |
LONG5B_LEN
Datentyp-Laenge in Byte. |
static int |
LONG6B_LEN
Datentyp-Laenge in Byte. |
static int |
LONG8B_LEN
Datentyp-Laenge in Byte. |
static byte[] |
SEPARATOR
Trennzeichenfolge zwischen Datensaetzen. |
| Constructor Summary | |
|---|---|
ByteIO()
|
|
| Method Summary | |
|---|---|
static int |
readSignedInt4Bytes(byte[] buf,
int pos)
Liest 4 Bytes im Byte-Array buf ab Stelle pos und liefert sie als Integer. |
static long |
readSignedLong8Byte(byte[] buf,
int pos)
Liest 8 Bytes im Byte-Array buf ab Stelle pos und liefert sie als Long. |
static long |
readUnsignedLong5Byte(byte[] buf,
int pos)
Liest 5 Bytes im Byte-Array buf ab Stelle pos und liefert sie als Long. |
static long |
readUnsignedLong6Byte(byte[] buf,
int pos)
Liest 6 Bytes im Byte-Array buf ab Stelle pos und liefert sie als Long. |
static int |
writeBytes(byte[] buf,
int pos,
byte[] b)
Schreibt das Quell-Byte-Array b in das Ziel-Byte-Array buf an die Stelle pos. |
static int |
writeSeparator(byte[] buf,
int pos)
Schreibt den Seperator an die angegebene Stelle im uebergebenen Array. |
static int |
writeSignedInt4Bytes(byte[] buf,
int pos,
int val)
Schreibt den Integer val in das Byte-Array buf an die Stelle pos. |
static int |
writeSignedLong8Byte(byte[] buf,
int pos,
long val)
Schreibt den Long val in das Byte-Array buf an die Stelle pos. |
static int |
writeUnsignedLong5Byte(byte[] buf,
int pos,
long val)
Schreibt die untersten 5 Byte des Long val in das Byte-Array buf an die Stelle pos. |
static int |
writeUnsignedLong6Byte(byte[] buf,
int pos,
long val)
Schreibt die untersten 6 Byte des Long val in das Byte-Array buf an die Stelle pos. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final byte[] SEPARATOR
public static final int INT4B_LEN
public static final int LONG8B_LEN
public static final int LONG5B_LEN
public static final int LONG6B_LEN
| Constructor Detail |
|---|
public ByteIO()
| Method Detail |
|---|
public static int writeSeparator(byte[] buf,
int pos)
buf - Byte-Arraypos - Position
public static int writeSignedInt4Bytes(byte[] buf,
int pos,
int val)
buf - Byte-Arraypos - Positionval - Integer-Wert
public static int writeSignedLong8Byte(byte[] buf,
int pos,
long val)
buf - Byte-Arraypos - Positionval - Long-Wert.
public static int writeUnsignedLong5Byte(byte[] buf,
int pos,
long val)
buf - Byte-Arraypos - Positionval - Long-Wert, nur die untersten 5 Byte werden beruecksichtigt
public static int writeUnsignedLong6Byte(byte[] buf,
int pos,
long val)
buf - Byte-Arraypos - Positionval - Long-Wert, nur die untersten 6 Byte werden beruecksichtigt (also auch nur positive Zahlen)
public static int writeBytes(byte[] buf,
int pos,
byte[] b)
buf - Ziel-Byte-Arraypos - Positionb - Quell-Byte-Array
public static int readSignedInt4Bytes(byte[] buf,
int pos)
buf - Byte-Array.pos - Position.
public static long readSignedLong8Byte(byte[] buf,
int pos)
buf - Byte-Arraypos - Position
public static long readUnsignedLong5Byte(byte[] buf,
int pos)
buf - Byte-Arraypos - Position
public static long readUnsignedLong6Byte(byte[] buf,
int pos)
buf - Byte-Arraypos - Position
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||