Package arc.util.io
Class Reads
java.lang.Object
arc.util.io.Reads
- All Implemented Interfaces:
Closeable
,AutoCloseable
A wrapper for DataInput with more concise method names and no IOExceptions.
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbyte
b()
read bytebyte[]
b
(byte[] array) read byte arraybyte[]
b
(byte[] array, int offset, int length) read byte array w/ offsetbyte[]
b
(int length) allocate & read byte arrayboolean
bool()
read booleanint
checkEOF()
void
close()
double
d()
read doublefloat
f()
read floatstatic Reads
int
i()
read intlong
l()
read longshort
s()
read shortvoid
skip
(int amount) skip bytesstr()
read string (UTF)int
ub()
read unsigned byteint
us()
read unsigned short
-
Field Details
-
input
-
-
Constructor Details
-
Reads
-
-
Method Details
-
get
-
checkEOF
public int checkEOF()- Returns:
- -1 if EOF or unsupported, or the next byte.
-
l
public long l()read long -
i
public int i()read int -
s
public short s()read short -
us
public int us()read unsigned short -
b
public byte b()read byte -
b
public byte[] b(int length) allocate & read byte array -
b
public byte[] b(byte[] array) read byte array -
b
public byte[] b(byte[] array, int offset, int length) read byte array w/ offset -
ub
public int ub()read unsigned byte -
bool
public boolean bool()read boolean -
f
public float f()read float -
d
public double d()read double -
str
read string (UTF) -
skip
public void skip(int amount) skip bytes -
close
public void close()- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
-