com.esri.arcgis.spatialanalyst
Interface IExtractionOp

All Superinterfaces:
Serializable
All Known Implementing Classes:
RasterExtractionOp

public interface IExtractionOp
extends Serializable

Provides access to members that control the extraction operations.

Superseded By

IExtractionOp2

Remarks

Spatial Analyst methods do not maintain colormaps in the output raster, therefore you can expect a loss of the color map when using methods of iExtractionOp. This happens during analysis where a new raster is being created and the input color map information is not carried over to the result. However, you can obtain and alter a raster dataset’s color map.

Assuming that pRasterDataset (IRasterDatset) and pColorMap (iRasterColorMap) have been created, the following code snippet applies a color map from one raster dataset to another.

'Get color map from Raster
Dim pColorMap As IRasterColormapSet
pColorMap = AccessRasterColorMap(pRasterDataSet01)

'Alter color map of raster02 to match raster01
Dim pRasterDatasetEdit As IRasterDatasetEdit
Set pRasterDatasetEdit = RasterDataSet02

pRasterDatasetEdit.AlterColormap pColorMap

Click on the following link to learn more about working with Raster Data: DataSourcesRaster Library Overview.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server. Requires Spatial Analyst Extension.


Method Summary
 IGeoDataset attribute(IRasterDescriptor raster)
          Extracts the cells of a raster based on a logical query.
 IGeoDataset circle(IGeoDataset geoDataset, ICircularArc circle, boolean selectInside)
          Extracts the cells of a raster based on a circle.
 IGeoDataset points(IGeoDataset geoDataset, IPointCollection points, boolean selectInside)
          Extracts the cells of a raster based on points.
 IGeoDataset polygon(IGeoDataset geoDataset, IPolygon polygon, boolean selectInside)
          Extracts the cells of a raster based on a polygon.
 IGeoDataset raster(IGeoDataset geoDataset, IGeoDataset maskRaster)
          Extracts the cells of a raster whose corresponding cells in the mask raster have valid value.
 IGeoDataset rectangle(IGeoDataset geoDataset, IEnvelope rectangleEnvelope, boolean selectInside)
          Extracts the cells of a raster based on a rectangle.
 ITable sample(IGeoDataset locationDataset, IGeoDataset collectionOfRasters, int resampleType)
          Extracts the cells of a raster based on a sample.
 

Method Detail

attribute

IGeoDataset attribute(IRasterDescriptor raster)
                      throws IOException,
                             AutomationException
Extracts the cells of a raster based on a logical query.

Remarks

raster

an input RasterDescriptor that was created by a logical expression based on the attributes in a Raster. Those cells for which the logical expression evaluated to True in the RasterDescriptor are selected. Those cells that are not selected will be set to NoData.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server. Requires Spatial Analyst Extension.

Supported Platforms

Windows, Solaris, Linux

Parameters:
raster - A reference to a com.esri.arcgis.geoanalyst.IRasterDescriptor (in)
Returns:
A reference to a com.esri.arcgis.geodatabase.IGeoDataset
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

circle

IGeoDataset circle(IGeoDataset geoDataset,
                   ICircularArc circle,
                   boolean selectInside)
                   throws IOException,
                          AutomationException
Extracts the cells of a raster based on a circle.

Remarks

geoDataset

an input Raster, RasterDataset, RasterBand, or RasterDescriptor

The geoDataset identifies the cell values which will be selected inside or outside of a specified circle.

Circle

an ICircularArc defining circle for the selection criteria

The coordinates are specified in map units and are in the same units as the geoDataset.

selectInside

a Boolean identifying which cells should be selected, those contained in or external to the input circle

If True, the cells inside the input CircleArc should be selected and written to the output Raster. All cells outside the circle will receive NoData on the output Raster.

If the Boolean is False, the cells outside the input circle should be selected and written to the output Raster. All cells inside the circle will receive NoData on the output Raster.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server. Requires Spatial Analyst Extension.

Supported Platforms

Windows, Solaris, Linux

Parameters:
geoDataset - A reference to a com.esri.arcgis.geodatabase.IGeoDataset (in)
circle - A reference to a com.esri.arcgis.geometry.ICircularArc (in)
selectInside - The selectInside (in)
Returns:
A reference to a com.esri.arcgis.geodatabase.IGeoDataset
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

raster

IGeoDataset raster(IGeoDataset geoDataset,
                   IGeoDataset maskRaster)
                   throws IOException,
                          AutomationException
Extracts the cells of a raster whose corresponding cells in the mask raster have valid value.

Remarks

geoDataset

an input Raster, RasterDataset, RasterBand, or RasterDescriptor

The geoDataset identifies the cell values which will be selected inside or outside of a specified polygon.

maskRaster

an input Raster, RasterDataset, RasterBand, or RasterDescriptor

The maskRaster identifies only those cells within the analysis extent that will be considered when performing an extraction. Only the identified cells will be processed in subsequent output raster datasets. All other cells are characterized as nodata.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server. Requires Spatial Analyst Extension.

Supported Platforms

Windows, Solaris, Linux

Parameters:
geoDataset - A reference to a com.esri.arcgis.geodatabase.IGeoDataset (in)
maskRaster - A reference to a com.esri.arcgis.geodatabase.IGeoDataset (in)
Returns:
A reference to a com.esri.arcgis.geodatabase.IGeoDataset
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

points

IGeoDataset points(IGeoDataset geoDataset,
                   IPointCollection points,
                   boolean selectInside)
                   throws IOException,
                          AutomationException
Extracts the cells of a raster based on points.

Remarks

geoDataset

an input Raster, RasterDataset, RasterBand, or RasterDescriptor

The geoDataset identifies the cell values which will be selected inside or outside a specified point.

Points

an IPointsCollection identifying the coordinates of the points to be selected

The coordinates are specified in map units and are in the same units as the geoDataset.

selectInside

a Boolean specifying which cells should be selected, those contained in or external to, the cell containing the selected point

If True, the cell in which the selected point falls will be written to the output Raster. All cells outside the box will receive NoData on the output Raster.

If the Boolean is False, the cells outside the input cells should be selected and written to the output Raster. The cell within which the selected point falls will receive NoData on the output Raster.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server. Requires Spatial Analyst Extension.

Supported Platforms

Windows, Solaris, Linux

Parameters:
geoDataset - A reference to a com.esri.arcgis.geodatabase.IGeoDataset (in)
points - A reference to a com.esri.arcgis.geometry.IPointCollection (in)
selectInside - The selectInside (in)
Returns:
A reference to a com.esri.arcgis.geodatabase.IGeoDataset
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

polygon

IGeoDataset polygon(IGeoDataset geoDataset,
                    IPolygon polygon,
                    boolean selectInside)
                    throws IOException,
                           AutomationException
Extracts the cells of a raster based on a polygon.

Remarks

geoDataset

an input Raster, RasterDataset, RasterBand, or RasterDescriptor

The geoDataset identifies the cell values which will be selected inside or outside of a specified polygon.

Polygon

an IPolygon defining polygon for the selection criteria

The coordinates are specified in map units and are in the same units as the geoDataset.

selectInside

a Boolean identifying which cells should be selected, those contained in or external to the input polygon

If True, the cells inside the input Polygon should be selected and written to the output Raster. All cells outside the polygon will receive NoData on the output Raster.

If False, the cells outside the input polygon should be selected and written to the output Raster. All cells inside the polygon will receive NoData on the output Raster.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server. Requires Spatial Analyst Extension.

Supported Platforms

Windows, Solaris, Linux

Parameters:
geoDataset - A reference to a com.esri.arcgis.geodatabase.IGeoDataset (in)
polygon - A reference to a com.esri.arcgis.geometry.IPolygon (in)
selectInside - The selectInside (in)
Returns:
A reference to a com.esri.arcgis.geodatabase.IGeoDataset
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

rectangle

IGeoDataset rectangle(IGeoDataset geoDataset,
                      IEnvelope rectangleEnvelope,
                      boolean selectInside)
                      throws IOException,
                             AutomationException
Extracts the cells of a raster based on a rectangle.

Remarks

geoDataset

an input Raster, RasterDataset, RasterBand, or RasterDescriptor identifying the cell values which will be selected inside or outside a specified rectangle

rectangleEnvelope

an IEnvelope identifying the lower-left and upper-right coordinates of the rectangle defining the selection criteria

The coordinates are specified in map units and are in the same units as the geoDataset.

selectInside

a Boolean specifying which cells should be selected, those contained in, or external to, the input rectangle

If True, then the cells inside the input rectangle should be selected and written to the output Raster. All cells outside the rectangle will receive NoData on the output Raster.

If False, then the cells outside the input rectangle should be selected and written to the output Raster. All cells inside the rectangle will receive NoData on the output Raster.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server. Requires Spatial Analyst Extension.

Supported Platforms

Windows, Solaris, Linux

Parameters:
geoDataset - A reference to a com.esri.arcgis.geodatabase.IGeoDataset (in)
rectangleEnvelope - A reference to a com.esri.arcgis.geometry.IEnvelope (in)
selectInside - The selectInside (in)
Returns:
A reference to a com.esri.arcgis.geodatabase.IGeoDataset
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

sample

ITable sample(IGeoDataset locationDataset,
              IGeoDataset collectionOfRasters,
              int resampleType)
              throws IOException,
                     AutomationException
Extracts the cells of a raster based on a sample.

Remarks

locationDataset

an input Raster, RasterDataset, RasterBand, RasterDescriptor, FeatureClass or FeatureClassDescriptor which defines the cells to sample

Cells in the locationDataSet with valid values will be sampled.

collectionOfRasters

a multiband input Raster, RasterDataset, RasterBand, or RasterDescriptor whose values will be sampled based upon the locationDataset

resampleType

an esriGeoAnalysisResampleEnum specifing the resampling algorithm to be used when sampling a Raster

resample enumeration types are,

esriGeoAnalysisBilinear - bilinear interpolation

esriGeoAnalysisCubic - cubic convolution

esriGeoAnalysisNearest - nearest neighbor assignment

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server. Requires Spatial Analyst Extension.

Supported Platforms

Windows, Solaris, Linux

Parameters:
locationDataset - A reference to a com.esri.arcgis.geodatabase.IGeoDataset (in)
collectionOfRasters - A reference to a com.esri.arcgis.geodatabase.IGeoDataset (in)
resampleType - A com.esri.arcgis.geoanalyst.esriGeoAnalysisResampleEnum constant (in)
Returns:
A reference to a com.esri.arcgis.geodatabase.ITable
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.