ch.javasoft.jsmat.variable
Class MatReserved

java.lang.Object
  extended by ch.javasoft.jsmat.variable.MatVariable
      extended by ch.javasoft.jsmat.variable.MatReserved
Direct Known Subclasses:
MatReservedComplex, MatReservedMatrix

public abstract class MatReserved
extends MatVariable

MatReserved is a variable which reserves space for data, but does not store (and allocate) the data itself. Such variables are somewhat more complicated to use than variables allocating data, but save memory since data is written piecewise.

See Also:
MatWriter.createReservedWriter(String, MatReservedMatrix), MatWriter.createReservedWriter(String, MatReservedComplex), ReservedWriter, ReservedMatrixWriter

Field Summary
 
Fields inherited from class ch.javasoft.jsmat.variable.MatVariable
DEFAULT_NAME, mDims, mMatClass
 
Constructor Summary
MatReserved(MatClass matClass, int[] dims)
           
 
Method Summary
abstract  void writeDataBlockEnd(DataOutput out)
          Called when the write process of the reserved variable is about to complete, that is, when ReservedWriter.close() is called.
abstract  void writeDataBlockStart(String name, DataOutput out)
           
 
Methods inherited from class ch.javasoft.jsmat.variable.MatVariable
checkRawDataSizeOverflow, checkValueLength, getDimLength, getFlags, getRawDataSize, getSize, writeStart
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MatReserved

public MatReserved(MatClass matClass,
                   int[] dims)
Method Detail

writeDataBlockStart

public abstract void writeDataBlockStart(String name,
                                         DataOutput out)
                                  throws IOException
Throws:
IOException

writeDataBlockEnd

public abstract void writeDataBlockEnd(DataOutput out)
                                throws IOException
Called when the write process of the reserved variable is about to complete, that is, when ReservedWriter.close() is called.

Throws:
IOException
See Also:
writeDataBlockStart(String, DataOutput)