Reusable Java library of general tools with minimal external dependencies.
For questions or support, please contact us:
Email: support@aoindustries.com
Phone: 1-800-519-9541
Phone: +1-251-607-9556
Web: https://aoindustries.com/contact
public class StreamableInput extends DataInputStream
in| Constructor and Description |
|---|
StreamableInput(InputStream in) |
read, read, readBoolean, readByte, readChar, readDouble, readFloat, readFully, readFully, readInt, readLine, readLong, readShort, readUnsignedByte, readUnsignedShort, readUTF, readUTF, skipBytesavailable, close, mark, markSupported, read, reset, skippublic StreamableInput(InputStream in)
public static int readCompressedInt(InputStream in) throws IOException
5 bit - 000SXXXX 13 bit - 001SXXXX XXXXXXXX 22 bit - 01SXXXXX XXXXXXXX XXXXXXXX 31 bit - 1SXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX
EOFException - if the end of file is reachedIOExceptionpublic int readCompressedInt()
throws IOException
5 bit - 000SXXXX 13 bit - 001SXXXX XXXXXXXX 22 bit - 01SXXXXX XXXXXXXX XXXXXXXX 31 bit - 1SXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX
EOFException - if the end of file is reachedIOExceptionpublic String readCompressedUTF() throws IOException
EOFException - if the end of file is reachedIOExceptionpublic String readNullUTF() throws IOException
IOExceptionpublic String readLongUTF() throws IOException
IOExceptionpublic String readNullLongUTF() throws IOException
null.IOExceptionpublic Byte readNullByte() throws IOException
IOExceptionpublic Short readNullShort() throws IOException
IOExceptionpublic Integer readNullInteger() throws IOException
IOExceptionpublic Long readNullLong() throws IOException
IOExceptionpublic <T extends Enum<T>> T readEnum(Class<T> enumType) throws IOException
Enum, represented by its Enum.name().IOExceptionpublic <T extends Enum<T>> T readNullEnum(Class<T> enumType) throws IOException
IOExceptionpublic Boolean readNullBoolean() throws IOException
IOExceptionpublic static Timestamp readTimestamp(DataInputStream in) throws IOException
Timestamp, maintaining the full nanosecond precision.
Time zone offset is not maintained.
See StreamableOutput.writeTimestamp(java.sql.Timestamp, java.io.DataOutputStream) for wire protocol details.
IOExceptionpublic Timestamp readTimestamp() throws IOException
Timestamp.IOExceptionreadTimestamp(java.io.DataInputStream)public Timestamp readNullTimestamp() throws IOException
null Timestamp.IOExceptionreadTimestamp()public static UnmodifiableTimestamp readUnmodifiableTimestamp(DataInputStream in) throws IOException
UnmodifiableTimestamp, maintaining the full nanosecond precision.
Time zone offset is not maintained.
See StreamableOutput.writeTimestamp(java.sql.Timestamp, java.io.DataOutputStream) for wire protocol details.
IOExceptionpublic UnmodifiableTimestamp readUnmodifiableTimestamp() throws IOException
UnmodifiableTimestamp.IOExceptionreadUnmodifiableTimestamp(java.io.DataInputStream)public UnmodifiableTimestamp readNullUnmodifiableTimestamp() throws IOException
null UnmodifiableTimestamp.IOExceptionreadUnmodifiableTimestamp()public Identifier readIdentifier() throws IOException
Identifier.IOExceptionpublic Identifier readNullIdentifier() throws IOException
null Identifier.IOExceptionpublic SmallIdentifier readSmallIdentifier() throws IOException
SmallIdentifier.IOExceptionpublic SmallIdentifier readNullSmallIdentifier() throws IOException
null Identifier.IOExceptionCopyright © 2000–2019 AO Industries, Inc.. All rights reserved.