uk.ac.leeds.ccg.andyt.grids.exchange
Class ESRIAsciiGridImporter

java.lang.Object
  extended by uk.ac.leeds.ccg.andyt.grids.exchange.ESRIAsciiGridImporter

public class ESRIAsciiGridImporter
extends java.lang.Object

Class for importing ESRI Asciigrid.


Field Summary
 Grid2DSquareCellProcessor _Grid2DSquareCellProcessor
           
 
Constructor Summary
ESRIAsciiGridImporter(java.io.File file, Grid2DSquareCellProcessor _Grid2DSquareCellProcessor)
           
ESRIAsciiGridImporter(java.io.File file, Grids_Environment _Grids_Environment)
          Creates a new instance of ESRIAsciiGridImporter
 
Method Summary
 void close()
          For closing this.bufferedReader.
 java.lang.String getFilenamePrefix()
          Returns the prefix (before "." part of filename of this.file.
 double readDouble()
          Returns the next value as a double or Double.NEGATIVE_INFINITY
 double[] readHeaderDouble()
          Reads the header of the file and returns a double[] where; [0] = (double) ncols; [1] = (double) nrows; [2] = xllcorner; [3] = yllcorner; [4] = cellsize; [5] = noDataValue if it exists or Double.NEGATIVE_INFINITY otherwise
 java.lang.Object[] readHeaderObject()
          Reads the header of the file and returns a Object[] where; [0] = Long( ncols ); [1] = (double) nrows; [2] = xllcorner; [3] = yllcorner; [4] = cellsize; [5] = noDataValue if it exists or Double.NEGATIVE_INFINITY otherwise
 int readInt()
          Returns the next value as a int or Integer.MIN_VALUE
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_Grid2DSquareCellProcessor

public Grid2DSquareCellProcessor _Grid2DSquareCellProcessor
Constructor Detail

ESRIAsciiGridImporter

public ESRIAsciiGridImporter(java.io.File file,
                             Grid2DSquareCellProcessor _Grid2DSquareCellProcessor)
Parameters:
file -
_Grid2DSquareCellProcessor -

ESRIAsciiGridImporter

public ESRIAsciiGridImporter(java.io.File file,
                             Grids_Environment _Grids_Environment)
Creates a new instance of ESRIAsciiGridImporter

Method Detail

readHeaderDouble

public double[] readHeaderDouble()
Reads the header of the file and returns a double[] where; [0] = (double) ncols; [1] = (double) nrows; [2] = xllcorner; [3] = yllcorner; [4] = cellsize; [5] = noDataValue if it exists or Double.NEGATIVE_INFINITY otherwise


readHeaderObject

public java.lang.Object[] readHeaderObject()
Reads the header of the file and returns a Object[] where; [0] = Long( ncols ); [1] = (double) nrows; [2] = xllcorner; [3] = yllcorner; [4] = cellsize; [5] = noDataValue if it exists or Double.NEGATIVE_INFINITY otherwise


readDouble

public double readDouble()
Returns the next value as a double or Double.NEGATIVE_INFINITY


readInt

public int readInt()
Returns the next value as a int or Integer.MIN_VALUE


close

public void close()
For closing this.bufferedReader.


getFilenamePrefix

public java.lang.String getFilenamePrefix()
Returns the prefix (before "." part of filename of this.file.