org.geotools.gce.arcgrid
Class ArcGridWriter

java.lang.Object
  extended by org.geotools.coverage.grid.io.AbstractGridCoverageWriter
      extended by org.geotools.gce.arcgrid.ArcGridWriter
All Implemented Interfaces:
org.opengis.coverage.grid.GridCoverageWriter

public final class ArcGridWriter
extends AbstractGridCoverageWriter
implements org.opengis.coverage.grid.GridCoverageWriter

ArcGridWriter supports writing of an ArcGrid GridCoverage to a Desination object XXX We cannot write a rotated grid coverage, we have to enforce that!

Author:
Daniele Romagnoli, Simone Giannecchini (simboss)

Field Summary
 
Fields inherited from class org.geotools.coverage.grid.io.AbstractGridCoverageWriter
destination, hints, outStream
 
Constructor Summary
ArcGridWriter(java.lang.Object destination)
          Takes either a URL or a String that points to an ArcGridCoverage file and converts it to a URL that can then be written to.
ArcGridWriter(java.lang.Object destination, Hints hints)
          Takes either a URL or a String that points to an ArcGridCoverage file and converts it to a URL that can then be written to.
 
Method Summary
 void dispose()
          Releases resources held by this AbstractGridCoverageWriter.
 org.opengis.coverage.grid.Format getFormat()
          Creates a Format object describing the Arc Grid Format
 void write(org.opengis.coverage.grid.GridCoverage coverage, org.opengis.parameter.GeneralParameterValue[] parameters)
          Note: The geotools GridCoverage class does not implement the geoAPI GridCoverage Interface so this method shows an error.
 
Methods inherited from class org.geotools.coverage.grid.io.AbstractGridCoverageWriter
finalize, getDestination, getMetadataNames, setCurrentSubname, setMetadataValue
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.opengis.coverage.grid.GridCoverageWriter
getDestination, getMetadataNames, setCurrentSubname, setMetadataValue
 

Constructor Detail

ArcGridWriter

public ArcGridWriter(java.lang.Object destination)
              throws DataSourceException
Takes either a URL or a String that points to an ArcGridCoverage file and converts it to a URL that can then be written to.

Parameters:
destination - the URL or String pointing to the file to load the ArcGrid
Throws:
DataSourceException

ArcGridWriter

public ArcGridWriter(java.lang.Object destination,
                     Hints hints)
              throws DataSourceException
Takes either a URL or a String that points to an ArcGridCoverage file and converts it to a URL that can then be written to.

Parameters:
destination - the URL or String pointing to the file to load the ArcGrid
Throws:
DataSourceException
Method Detail

getFormat

public org.opengis.coverage.grid.Format getFormat()
Creates a Format object describing the Arc Grid Format

Specified by:
getFormat in interface org.opengis.coverage.grid.GridCoverageWriter
Returns:
the format of the data source we will write to. (ArcGridFormat in this case)
See Also:
GridCoverageWriter.getFormat()

write

public void write(org.opengis.coverage.grid.GridCoverage coverage,
                  org.opengis.parameter.GeneralParameterValue[] parameters)
           throws java.lang.IllegalArgumentException,
                  java.io.IOException
Note: The geotools GridCoverage class does not implement the geoAPI GridCoverage Interface so this method shows an error. All other methods are using the geotools GridCoverage class

Specified by:
write in interface org.opengis.coverage.grid.GridCoverageWriter
Throws:
java.lang.IllegalArgumentException
java.io.IOException
See Also:
GridCoverageWriter.write(org.opengis.coverage.grid.GridCoverage, org.opengis.parameter.GeneralParameterValue[])

dispose

public void dispose()
Description copied from class: AbstractGridCoverageWriter
Releases resources held by this AbstractGridCoverageWriter.

Specified by:
dispose in interface org.opengis.coverage.grid.GridCoverageWriter
Overrides:
dispose in class AbstractGridCoverageWriter
See Also:
GridCoverageWriter.dispose()


Copyright © 1996-2010 Geotools. All Rights Reserved.