edu.harvard.hul.ois.jhove.module.wave
Class FormatChunk

java.lang.Object
  extended by edu.harvard.hul.ois.jhove.module.iff.Chunk
      extended by edu.harvard.hul.ois.jhove.module.wave.FormatChunk

public class FormatChunk
extends Chunk

Implementation of the WAVE Format Chunk.

Author:
Gary McGath

Field Summary
static int WAVE_FORMAT_EXTENSIBLE
          Compression code for Microsoft Extensible Wave Format
static int WAVE_FORMAT_MPEG
          Compression code for MPEG
static int WAVE_FORMAT_PCM
          Compression code for original Microsoft PCM
 
Fields inherited from class edu.harvard.hul.ois.jhove.module.iff.Chunk
_dstream, _module, bytesLeft
 
Constructor Summary
FormatChunk(WaveModule module, ChunkHeader hdr, java.io.DataInputStream dstrm)
          Constructor.
 
Method Summary
 boolean readChunk(RepInfo info)
          Reads a chunk and puts appropriate Properties into the RepInfo object.
 
Methods inherited from class edu.harvard.hul.ois.jhove.module.iff.Chunk
byteBufString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

WAVE_FORMAT_PCM

public static final int WAVE_FORMAT_PCM
Compression code for original Microsoft PCM

See Also:
Constant Field Values

WAVE_FORMAT_MPEG

public static final int WAVE_FORMAT_MPEG
Compression code for MPEG

See Also:
Constant Field Values

WAVE_FORMAT_EXTENSIBLE

public static final int WAVE_FORMAT_EXTENSIBLE
Compression code for Microsoft Extensible Wave Format

See Also:
Constant Field Values
Constructor Detail

FormatChunk

public FormatChunk(WaveModule module,
                   ChunkHeader hdr,
                   java.io.DataInputStream dstrm)
Constructor.

Parameters:
module - The WaveModule under which this was called
hdr - The header for this chunk
dstrm - The stream from which the WAVE data are being read
Method Detail

readChunk

public boolean readChunk(RepInfo info)
                  throws java.io.IOException,
                         JhoveException
Reads a chunk and puts appropriate Properties into the RepInfo object.

Specified by:
readChunk in class Chunk
Parameters:
info - RepInfo object to receive information
Returns:
false if the chunk is structurally invalid, otherwise true
Throws:
JhoveException
java.io.IOException