Class OpenJUMPSextanteRasterLayer

java.lang.Object
org.openjump.core.rasterimage.sextante.AbstractSextanteRasterLayer
org.openjump.core.rasterimage.sextante.OpenJUMPSextanteRasterLayer
All Implemented Interfaces:
ISextanteDataObject, ISextanteLayer, ISextanteRasterLayer

public class OpenJUMPSextanteRasterLayer extends AbstractSextanteRasterLayer
  • Constructor Details

    • OpenJUMPSextanteRasterLayer

      public OpenJUMPSextanteRasterLayer()
  • Method Details

    • create

      public void create(RasterImageLayer layer) throws IOException
      Throws:
      IOException
    • create

      public void create(RasterImageLayer layer, boolean loadFromFile) throws IOException
      Throws:
      IOException
    • create

      public void create(String name, String filename, GridExtent ge, int dataType, int numBands, Object crs, LayerManager layerManager)
    • fitToGridExtent

      public void fitToGridExtent(GridExtent ge, LayerManager layerManager)
      Description copied from interface: ISextanteRasterLayer
      Resamples the layer so the new full extent is the same as a given gridExtent
      Parameters:
      ge - the reference gridExtent
      layerManager - the LayerManager
    • getBandsCount

      public int getBandsCount()
      Description copied from interface: ISextanteRasterLayer
      Returns the number of bands of the layer
      Returns:
      the number of bands of the layer
    • getCellValueInLayerCoords

      public double getCellValueInLayerCoords(int x, int y, int band)
      Description copied from interface: ISextanteRasterLayer
      Returns the value of a cell in the original image coords, that is, not using the query window
      Parameters:
      x - the x coordinate(col) of the cell
      y - the y coordinate(row) of the cell
      band - the band to be queried
      Returns:
      the value of a cell in the original image coords.
    • getDataType

      public int getDataType()
      Description copied from interface: ISextanteRasterLayer
      Returns the data type of the layer
      Returns:
      the data type of the layer
    • getLayerCellSize

      public Point2D.Double getLayerCellSize()
      Description copied from interface: ISextanteRasterLayer
      Return the original cellsize of the layer. X and Y cellsizes are assumed to be equal
      Returns:
      the original cellsize of the layer
    • getLayerGridExtent

      public GridExtent getLayerGridExtent()
      Description copied from interface: ISextanteRasterLayer
      Returns the grid extent of the layer
      Returns:
      the grid extent of the layer
    • getNoDataValue

      public double getNoDataValue()
      Description copied from interface: ISextanteRasterLayer
      Gets the no-data value of the layer
      Returns:
      the no-data value of the layer
    • setCellValue

      public void setCellValue(int x, int y, int band, double value)
      Description copied from interface: ISextanteRasterLayer
      Sets the value at a cell
      Parameters:
      x - the x coordinate (cols)
      y - the y coordinate (rows)
      band - the band (zero-based)
      value - the new value
    • setNoDataValue

      public void setNoDataValue(double noDataValue)
      Description copied from interface: ISextanteRasterLayer
      Sets the no-data value of the layer
      Parameters:
      noDataValue - the new no-data value
    • getCRS

      public Object getCRS()
      Description copied from interface: ISextanteLayer
      Returns an object with information about the CRS associated to this layer. The class of this object depends on the implementation of this interface
      Returns:
      An object with information about the CRS used for this layer (i.e. a string with a EPSG code)
    • getFullExtent

      public Rectangle2D getFullExtent()
      Returns the extent covered by the layer
      Returns:
      the extent of the layer
    • open

      public void open()
      Description copied from interface: ISextanteDataObject
      This methods initialize the data object, so it is ready to be accessed
    • close

      public void close()
      Description copied from interface: ISextanteDataObject
      This method closes the data object, which was opened using the open() method.
    • postProcess

      public void postProcess() throws Exception
      Description copied from interface: ISextanteDataObject
      This method post-processes the object after it has been created. If, for instance, data are kept in memory before they are dumped to file, this method should write that file.
      Throws:
      Exception - if an Exception occurs during post-processing
    • getFilename

      public String getFilename()
      Description copied from interface: ISextanteDataObject
      Returns the filename associated to this data object.
      Returns:
      the filename associated to this data object. Can be null, since the object wrapped by this class doesn't have to be file-based.
    • getName

      public String getName()
      Description copied from interface: ISextanteDataObject
      Returns the name of this data object
      Returns:
      the name of this data object
    • setName

      public void setName(String sName)
      Description copied from interface: ISextanteDataObject
      Sets a new name for this object
      Parameters:
      sName - the new name