public abstract class Chunk extends Object
Modifier and Type | Field and Description |
---|---|
protected DataInputStream |
_dstream |
protected ModuleBase |
_module |
protected long |
bytesLeft |
Constructor and Description |
---|
Chunk(ModuleBase module,
ChunkHeader hdr,
DataInputStream dstrm)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
protected String |
byteBufString(byte[] b)
Convert a byte buffer cleanly to an ASCII string.
|
abstract boolean |
readChunk(RepInfo info)
Reads a chunk and puts appropriate information into
the RepInfo object.
|
protected ModuleBase _module
protected long bytesLeft
protected DataInputStream _dstream
public Chunk(ModuleBase module, ChunkHeader hdr, DataInputStream dstrm)
module
- The Module under which this was calledhdr
- The header for this chunkdstrm
- The stream from which the data are being readpublic abstract boolean readChunk(RepInfo info) throws IOException, JhoveException
info
- RepInfo object to receive informationfalse
if the chunk is structurally
invalid, otherwise true
JhoveException
IOException
protected String byteBufString(byte[] b)
Copyright © 2008–2017 The Open Preservation Foundation. All rights reserved.