databionics.io
Class Array3DFile

java.lang.Object
  extended by databionics.io.BaseFile
      extended by databionics.io.Array2DFile
          extended by databionics.io.Array3DFile
Direct Known Subclasses:
WtsFile

public abstract class Array3DFile
extends Array2DFile

Base class for all filetypes with 3D data arrays actually stored in 3D array.


Field Summary
protected  int cols
          Number of columns of 3D array.
protected static org.apache.log4j.Logger log
          Log4j logging.
protected  int rows
          Number of rows of 3D array.
 
Fields inherited from class databionics.io.Array2DFile
data
 
Fields inherited from class databionics.io.BaseFile
allowEmptyLines, comment, commentPrefix, delimiter, delimiters, file, header, headerPrefix, loc, nf
 
Constructor Summary
Array3DFile()
          Standard constructor
Array3DFile(int rows, int cols, int dim)
          Constructor with size for an empty array.
Array3DFile(java.lang.String filename)
          Constructor with a filename
 
Method Summary
protected  void buildHeader()
          Generate header.
 int getColumns()
          Get number of columns of the pseudo 3d matrix.
 int getDimensions()
          Get number of dimensions of the pseudo 3d matrix.
 int getRows()
          Get number of rows of the pseudo 3d matrix.
protected  void init(int rows, int cols, int dim)
          Initialize 3D as 2D array.
protected  void parseHeader()
          Parse the header.
 
Methods inherited from class databionics.io.Array2DFile
buildLine, get, getData, getSize, init, parseLine, set, setData, setData
 
Methods inherited from class databionics.io.BaseFile
checkHeader, checkHeaderAgainstSize, getComment, getFile, getFilename, getHeader, getLocale, getNumberFormat, isHeader, isNaN, isNumber, load, load, parseError, save, save, setComment, setFilename, setLocale, writeStringList, writeStringList
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

protected static org.apache.log4j.Logger log
Log4j logging.


rows

protected int rows
Number of rows of 3D array.


cols

protected int cols
Number of columns of 3D array.

Constructor Detail

Array3DFile

public Array3DFile()
Standard constructor


Array3DFile

public Array3DFile(java.lang.String filename)
Constructor with a filename

Parameters:
filename - Name of the file

Array3DFile

public Array3DFile(int rows,
                   int cols,
                   int dim)
Constructor with size for an empty array.

Parameters:
rows - Rows of data array.
cols - Columns of data array.
dim - Dimension of data array.
Method Detail

parseHeader

protected void parseHeader()
Parse the header.

Overrides:
parseHeader in class BaseFile

init

protected void init(int rows,
                    int cols,
                    int dim)
Initialize 3D as 2D array.

Parameters:
rows - Rows of 3D data array.
cols - Columns of 3D data array.
dim - Dimension of 3D data array.

buildHeader

protected void buildHeader()
Generate header.

Overrides:
buildHeader in class Array2DFile

getDimensions

public int getDimensions()
Get number of dimensions of the pseudo 3d matrix.


getColumns

public int getColumns()
Get number of columns of the pseudo 3d matrix.

Overrides:
getColumns in class Array2DFile

getRows

public int getRows()
Get number of rows of the pseudo 3d matrix.

Overrides:
getRows in class Array2DFile


Copyright © 2005-2006 Databionics Research Group. All Rights Reserved.