javax.imageio.stream
Class FileImageOutputStream

java.lang.Object
  extended by javax.imageio.stream.ImageInputStreamImpl
      extended by javax.imageio.stream.ImageOutputStreamImpl
          extended by javax.imageio.stream.FileImageOutputStream
All Implemented Interfaces:
DataInput, DataOutput, ImageInputStream, ImageOutputStream

public class FileImageOutputStream
extends ImageOutputStreamImpl


Field Summary
 
Fields inherited from class javax.imageio.stream.ImageInputStreamImpl
bitOffset, byteOrder, flushedPos, streamPos
 
Constructor Summary
FileImageOutputStream(File file)
           
FileImageOutputStream(RandomAccessFile file)
           
 
Method Summary
 void close()
           
 long length()
           
 int read()
           
 int read(byte[] data, int offset, int len)
           
 void seek(long position)
           
 void write(byte[] data, int offset, int len)
          Writes a region of data from an array into the stream.
 void write(int value)
          Writes an int into the stream.
 
Methods inherited from class javax.imageio.stream.ImageOutputStreamImpl
flushBits, write, writeBit, writeBits, writeBoolean, writeByte, writeBytes, writeChar, writeChars, writeChars, writeDouble, writeDoubles, writeFloat, writeFloats, writeInt, writeInts, writeLong, writeLongs, writeShort, writeShorts, writeUTF
 
Methods inherited from class javax.imageio.stream.ImageInputStreamImpl
checkClosed, finalize, flush, flushBefore, getBitOffset, getByteOrder, getFlushedPosition, getStreamPosition, isCached, isCachedFile, isCachedMemory, mark, read, readBit, readBits, readBoolean, readByte, readBytes, readChar, readDouble, readFloat, readFully, readFully, readFully, readFully, readFully, readFully, readFully, readFully, readInt, readLine, readLong, readShort, readUnsignedByte, readUnsignedInt, readUnsignedShort, readUTF, reset, setBitOffset, setByteOrder, skipBytes, skipBytes
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.imageio.stream.ImageOutputStream
flushBefore
 
Methods inherited from interface javax.imageio.stream.ImageInputStream
flush, getBitOffset, getByteOrder, getFlushedPosition, getStreamPosition, isCached, isCachedFile, isCachedMemory, mark, read, readBit, readBits, readBoolean, readByte, readBytes, readChar, readDouble, readFloat, readFully, readFully, readFully, readFully, readFully, readFully, readFully, readFully, readInt, readLine, readLong, readShort, readUnsignedByte, readUnsignedInt, readUnsignedShort, readUTF, reset, setBitOffset, setByteOrder, skipBytes, skipBytes
 

Constructor Detail

FileImageOutputStream

public FileImageOutputStream(File file)
                      throws FileNotFoundException,
                             IOException
Throws:
FileNotFoundException
IOException

FileImageOutputStream

public FileImageOutputStream(RandomAccessFile file)
Method Detail

close

public void close()
           throws IOException
Specified by:
close in interface ImageInputStream
Overrides:
close in class ImageInputStreamImpl
Throws:
IOException

length

public long length()
Specified by:
length in interface ImageInputStream
Overrides:
length in class ImageInputStreamImpl

read

public int read()
         throws IOException
Specified by:
read in interface ImageInputStream
Specified by:
read in class ImageInputStreamImpl
Throws:
IOException

read

public int read(byte[] data,
                int offset,
                int len)
         throws IOException
Specified by:
read in interface ImageInputStream
Specified by:
read in class ImageInputStreamImpl
Throws:
IOException

seek

public void seek(long position)
          throws IOException
Specified by:
seek in interface ImageInputStream
Overrides:
seek in class ImageInputStreamImpl
Throws:
IOException

write

public void write(byte[] data,
                  int offset,
                  int len)
           throws IOException
Description copied from interface: ImageOutputStream
Writes a region of data from an array into the stream.

Specified by:
write in interface DataOutput
Specified by:
write in interface ImageOutputStream
Specified by:
write in class ImageOutputStreamImpl
Parameters:
data - the data to be written
offset - the offset in the array
len - the length in the array
Throws:
IOException - if an errror occurs

write

public void write(int value)
           throws IOException
Description copied from interface: ImageOutputStream
Writes an int into the stream.

Specified by:
write in interface DataOutput
Specified by:
write in interface ImageOutputStream
Specified by:
write in class ImageOutputStreamImpl
Parameters:
value - the data to be written
Throws:
IOException - if an errror occurs