net.netheos.pcsapi.bytesio
Interface ByteSource

All Known Implementing Classes:
FileByteSource, MemoryByteSource, ProgressByteSource, RangeByteSource

public interface ByteSource

Readable source of bytes that supplies an ByteSink


Method Summary
 long length()
          Return length of stream (must be known before consuming stream)
 InputStream openStream()
          Returns a ByteSourceStream object for reading data, to be closed by caller
 

Method Detail

openStream

InputStream openStream()
                       throws IOException
Returns a ByteSourceStream object for reading data, to be closed by caller

Returns:
the underlying stream
Throws:
IOException

length

long length()
Return length of stream (must be known before consuming stream)

Returns:
The stream bytes count


Copyright © 2014. All Rights Reserved.