Package ch.randelshofer.io
Class ByteArrayImageInputStream
java.lang.Object
java.io.InputStream
java.io.ByteArrayInputStream
ch.randelshofer.io.ByteArrayImageInputStream
- All Implemented Interfaces:
Closeable,DataInput,AutoCloseable,ImageInputStream
ByteArrayImageInputStream.
-
Constructor Summary
ConstructorsConstructorDescriptionByteArrayImageInputStream(byte[] buf) ByteArrayImageInputStream(byte[] buf, int offset, int length, ByteOrder byteOrder) ByteArrayImageInputStream(byte[] buf, ByteOrder byteOrder) -
Method Summary
Modifier and TypeMethodDescriptionvoidflush()voidflushBefore(long pos) intlonglongbooleanisCached()booleanbooleanlonglength()voidmark()intreadBit()longreadBits(int numBits) booleanbytereadByte()voidreadBytes(IIOByteBuffer buf, int len) charreadChar()doublefloatvoidreadFully(byte[] b) voidreadFully(byte[] b, int off, int len) voidreadFully(char[] c, int off, int len) voidreadFully(double[] d, int off, int len) voidreadFully(float[] f, int off, int len) voidreadFully(int[] i, int off, int len) voidreadFully(long[] l, int off, int len) voidreadFully(short[] s, int off, int len) intreadInt()readLine()longreadLong()shortintlongintreadUTF()voidreset()voidseek(long pos) voidsetBitOffset(int bitOffset) voidsetByteOrder(ByteOrder byteOrder) intskipBytes(int n) longskipBytes(long n) Methods inherited from class java.io.ByteArrayInputStream
available, close, mark, markSupported, read, read, readAllBytes, readNBytes, skip, transferToMethods inherited from class java.io.InputStream
nullInputStream, read, readNBytes, skipNBytesMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface javax.imageio.stream.ImageInputStream
close, read, read, read
-
Constructor Details
-
ByteArrayImageInputStream
public ByteArrayImageInputStream(byte[] buf) -
ByteArrayImageInputStream
-
ByteArrayImageInputStream
-
-
Method Details
-
setByteOrder
- Specified by:
setByteOrderin interfaceImageInputStream
-
getByteOrder
- Specified by:
getByteOrderin interfaceImageInputStream
-
readBytes
- Specified by:
readBytesin interfaceImageInputStream- Throws:
IOException
-
readBoolean
- Specified by:
readBooleanin interfaceDataInput- Specified by:
readBooleanin interfaceImageInputStream- Throws:
IOException
-
readByte
- Specified by:
readBytein interfaceDataInput- Specified by:
readBytein interfaceImageInputStream- Throws:
IOException
-
readUnsignedByte
- Specified by:
readUnsignedBytein interfaceDataInput- Specified by:
readUnsignedBytein interfaceImageInputStream- Throws:
IOException
-
readShort
- Specified by:
readShortin interfaceDataInput- Specified by:
readShortin interfaceImageInputStream- Throws:
IOException
-
readUnsignedShort
- Specified by:
readUnsignedShortin interfaceDataInput- Specified by:
readUnsignedShortin interfaceImageInputStream- Throws:
IOException
-
readChar
- Specified by:
readCharin interfaceDataInput- Specified by:
readCharin interfaceImageInputStream- Throws:
IOException
-
readInt
- Specified by:
readIntin interfaceDataInput- Specified by:
readIntin interfaceImageInputStream- Throws:
IOException
-
readUnsignedInt
- Specified by:
readUnsignedIntin interfaceImageInputStream- Throws:
IOException
-
readLong
- Specified by:
readLongin interfaceDataInput- Specified by:
readLongin interfaceImageInputStream- Throws:
IOException
-
readFloat
- Specified by:
readFloatin interfaceDataInput- Specified by:
readFloatin interfaceImageInputStream- Throws:
IOException
-
readDouble
- Specified by:
readDoublein interfaceDataInput- Specified by:
readDoublein interfaceImageInputStream- Throws:
IOException
-
readLine
- Specified by:
readLinein interfaceDataInput- Specified by:
readLinein interfaceImageInputStream- Throws:
IOException
-
readUTF
- Specified by:
readUTFin interfaceDataInput- Specified by:
readUTFin interfaceImageInputStream- Throws:
IOException
-
readFully
- Specified by:
readFullyin interfaceDataInput- Specified by:
readFullyin interfaceImageInputStream- Throws:
IOException
-
readFully
- Specified by:
readFullyin interfaceDataInput- Specified by:
readFullyin interfaceImageInputStream- Throws:
IOException
-
readFully
- Specified by:
readFullyin interfaceImageInputStream- Throws:
IOException
-
readFully
- Specified by:
readFullyin interfaceImageInputStream- Throws:
IOException
-
readFully
- Specified by:
readFullyin interfaceImageInputStream- Throws:
IOException
-
readFully
- Specified by:
readFullyin interfaceImageInputStream- Throws:
IOException
-
readFully
- Specified by:
readFullyin interfaceImageInputStream- Throws:
IOException
-
readFully
- Specified by:
readFullyin interfaceImageInputStream- Throws:
IOException
-
getStreamPosition
public long getStreamPosition()- Specified by:
getStreamPositionin interfaceImageInputStream
-
getBitOffset
public int getBitOffset()- Specified by:
getBitOffsetin interfaceImageInputStream
-
setBitOffset
public void setBitOffset(int bitOffset) - Specified by:
setBitOffsetin interfaceImageInputStream
-
readBit
- Specified by:
readBitin interfaceImageInputStream- Throws:
IOException
-
readBits
- Specified by:
readBitsin interfaceImageInputStream- Throws:
IOException
-
length
- Specified by:
lengthin interfaceImageInputStream- Throws:
IOException
-
skipBytes
- Specified by:
skipBytesin interfaceDataInput- Specified by:
skipBytesin interfaceImageInputStream- Throws:
IOException
-
skipBytes
- Specified by:
skipBytesin interfaceImageInputStream- Throws:
IOException
-
seek
- Specified by:
seekin interfaceImageInputStream- Throws:
IOException
-
flushBefore
- Specified by:
flushBeforein interfaceImageInputStream- Throws:
IOException
-
flush
- Specified by:
flushin interfaceImageInputStream- Throws:
IOException
-
getFlushedPosition
public long getFlushedPosition()- Specified by:
getFlushedPositionin interfaceImageInputStream
-
isCached
public boolean isCached()- Specified by:
isCachedin interfaceImageInputStream
-
isCachedMemory
public boolean isCachedMemory()- Specified by:
isCachedMemoryin interfaceImageInputStream
-
isCachedFile
public boolean isCachedFile()- Specified by:
isCachedFilein interfaceImageInputStream
-
mark
public void mark()- Specified by:
markin interfaceImageInputStream
-
reset
public void reset()- Specified by:
resetin interfaceImageInputStream- Overrides:
resetin classByteArrayInputStream
-