org.eclipse.smila.taskworker.input
Class StreamInput
java.lang.Object
org.eclipse.smila.taskworker.io.IODataObject
org.eclipse.smila.taskworker.input.Input
org.eclipse.smila.taskworker.input.StreamInput
public class StreamInput
- extends Input
Provides direct access to the InputStream for reading from objectstore. Play with each single byte as you
like.
|
Method Summary |
void |
close()
close objectstore stream, if open. |
long |
getBytesRead()
|
java.util.Map<java.lang.String,java.lang.Number> |
getCounter()
create basic counter map. |
java.io.InputStream |
getStream()
get reading stream to objectstore object. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
StreamInput
public StreamInput(BulkInfo dataObject,
ObjectStoreService objectStore)
- create instance.
getStream
public java.io.InputStream getStream()
throws ObjectStoreException
- get reading stream to objectstore object.
- Throws:
ObjectStoreException
close
public void close()
- close objectstore stream, if open.
- Specified by:
close in class Input
getBytesRead
public long getBytesRead()
- Returns:
- size of data read from stream. Is only valid after input is closed.
getCounter
public java.util.Map<java.lang.String,java.lang.Number> getCounter()
- Description copied from class:
IODataObject
- create basic counter map.
- Overrides:
getCounter in class IODataObject
- Returns:
- counter map of superclass extended by the number of bytes read from the stream.
toString
public java.lang.String toString()
- Overrides:
toString in class java.lang.Object