uk.me.parabola.imgfmt.mps
Class Block

java.lang.Object
  extended by uk.me.parabola.imgfmt.mps.Block
Direct Known Subclasses:
MapBlock, MapsetBlock, ProductBlock

public abstract class Block
extends java.lang.Object

All the blocks in the file have a type and a length.

Author:
Steve Ratcliffe

Constructor Summary
protected Block(int type)
           
 
Method Summary
 void write(ImgChannel chan)
           
protected abstract  void writeBody(StructuredOutputStream out)
          Writes the body to the output stream given.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Block

protected Block(int type)
Method Detail

write

public void write(ImgChannel chan)
           throws java.io.IOException
Throws:
java.io.IOException

writeBody

protected abstract void writeBody(StructuredOutputStream out)
                           throws java.io.IOException
Writes the body to the output stream given.

Parameters:
out - The stream to write to.
Throws:
java.io.IOException