org.jaudiotagger.audio.asf.io
Interface ChunkModifier

All Known Implementing Classes:
AsfExtHeaderModifier, ChunkRemover, WriteableChunkModifer

public interface ChunkModifier

Reads an ASF chunk and writes a modified copy.

Author:
Christian Laireiter

Method Summary
 boolean isApplicable(GUID guid)
          Determines, whether the modifier handles chunks identified by given guid.
 ModificationResult modify(GUID guid, java.io.InputStream source, java.io.OutputStream destination)
          Writes a modified copy of the chunk into the destination..
 

Method Detail

isApplicable

boolean isApplicable(GUID guid)
Determines, whether the modifier handles chunks identified by given guid.

Parameters:
guid - GUID to test.
Returns:
true, if this modifier can be used to modify the chunk.

modify

ModificationResult modify(GUID guid,
                          java.io.InputStream source,
                          java.io.OutputStream destination)
                          throws java.io.IOException
Writes a modified copy of the chunk into the destination..

Parameters:
guid - GUID of the chunk to modify.
source - a stream providing the chunk, starting at the chunks length field.
destination - destination for the modified chunk.
Returns:
the differences between source and destination.
Throws:
java.io.IOException - on I/O errors.