|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.esri.arcgis.datasourcesraster.RasterDataset
public class RasterDataset
A representation of a raster dataset on disk.
The RasterDataset object represents a dataset on disk or in a geodatabase. It is composed of one or more persistent raster bands.
The RasterDataset object performs basic dataset management functions, such as copy, rename, and delete. It can also be used to examine dataset properties including raster format, extent, spatial reference, and number of bands, etc.
RasterDataset can be used to change some of the properties of the dataset. For example, RasterDataset can be used to change the spatial reference associated with the dataset, to manipulate the colormap of the raster dataset, to build pyramids (reduced-resolution datasets) which improve display performance for large raster datasets, and to build statistics which enhances raster renderering. RasterDataset object can merge pixels from another raster dataset to itself.
A RasterDataset can be saved to anther file format or geodatabase using ISaveAs or IRasterBandCollection.
The IRasterWorkspace interface and IRasterWorkspaceEx interface, through an Access workspace, create a file based RasterDataset; IRasterWorkspaceEx interface, through a database workspace, creates a database RasterDataset.
A file based RasterDataset and database RasterDataset work the same way except on a few interfaces. For example, ITemporyDataset and IWorldFileExport interfaces are not supported by a database RasterDataset.
The RasterDataset object represents a dataset on disk or in a database. It is composed of one or more persistent raster bands. The dataset provides access only to operations that apply to the entire dataset, with the RasterBand providing access to operations that occur on individual bands.
The RasterDataset object performs basic dataset management functions, such as copy, rename, and delete. It can also instantiat RasterBand and Raster objects representing other aspects of the data. It can be used to examine dataset properties including different format, extent, spatial reference, and number of bands.
The spatial reference of the raster raster dataset can be changed through interface IGeoDatasetSchemaEdit, but it does not project the dataset, only changes the coordinate system associated with the dataset.
The pyramid of the raster dataset can be built or rebuilt to improve display performance for large raster datasets.
| Constructor Summary | |
|---|---|
RasterDataset()
Constructs a RasterDataset using ArcGIS Engine. |
|
RasterDataset(Object obj)
Deprecated. As of ArcGIS 9.2, replaced by normal Java casts. RasterDataset theRasterDataset = (RasterDataset) obj; |
|
| Method Summary | |
|---|---|
void |
add(IRasterBand element,
int index)
Adds a RasterBand to the band collection. |
void |
alterAttributeTable(ITable newTable)
Alters the raster attribute table. |
void |
alterColormap(IRasterColormap colormap)
Alters colormap. |
void |
alterGeodataXform(IGeodataXform xform)
Alters the geodata transformation of the dataset (does not transform the data). |
void |
alterResolution(double xyResolution,
double zResolution,
double mResolution)
Alters the resolution of the dataset and rebuilds the spatial indexes. |
void |
alterSpatialReference(ISpatialReference spatialReference)
Alters the spatial reference of the dataset to match the coordinate system of the input spatial reference, does not reproject the data. |
void |
analyze(int tableComponents)
Analyze the data to update/generate DBMS statistics. |
void |
appendBand(IRasterBand element)
Appends a RasterBand to the band collection. |
void |
appendBands(IRasterBandCollection bands)
Appends a collection of RasterBands to the band collection. |
void |
appendNewBand()
Appends a new raster band. |
void |
buildAttributeTable()
Builds the raster attribute table. |
void |
buildPyramid(int maxLevel,
int method)
Builds pyramid for this RasterDataset. |
boolean |
canCopy()
Returns true if this dataset can be copied. |
boolean |
canDelete()
True if this dataset can be deleted. |
boolean |
canRename()
True if this dataset can be renamed. |
boolean |
canSaveAs(String format)
Checks if it's can be saved as a new persistent Dataset of a given format. |
void |
clear()
Removes all the elements in the collection. |
void |
computeStatisticsHistogram(int skipx,
int skipy,
Object ignoreValues,
boolean requireHistogram)
Computes statistics and histogram for a skip factor and a list of Ignore vlaues. |
void |
computeStats(int pyramidLevel)
Calculates statistics and histograms from a given pyramid level. |
void |
constructResolutions(ISpatialReference spatialReference,
int numberRequested,
int[] defaultXYResolutionIndex,
IDoubleArray[] xyResolutions,
IDoubleArray[] zResolutions,
IDoubleArray[] mResolutions)
Returns a list of possible resolutions (precisions) and the doubling factors that produce them from the specified low precision spatial reference. |
IDataset |
copy(String copyName,
IWorkspace copyWorkspace)
Copies this dataset to a new dataset with the specified name. |
void |
create()
Build raster pyramids for this raster. |
IRaster |
createDefaultRaster()
Creates a raster object with the default properties for this dataset. |
IRaster |
createFullRaster()
Creates a raster containing all bands in this raster dataset. |
IPixelBlock |
createPixelBlock()
Create a compatible pixel block. |
IRaster |
createRaster()
Creates an empty raster. |
void |
delete()
Deletes this dataset. |
void |
deleteAttributeTable()
Deletes the raster attribute table. |
void |
deleteColormap()
Deletes colormap. |
void |
deletePyramid()
Deletes pyramid for this RasterDataset. |
void |
deleteStats()
Deletes statistics and histograms. |
boolean |
equals(Object o)
Compare this object with another |
void |
erase(IEnvelope extent)
Erases a rectanglar area of this RasterDataset. |
void |
flush()
Flushes buffered data. |
int |
getAllowableComponents()
The allowable components to be analyzed. |
IRasterBand |
getBandByName(String name)
A RasterBand given its name. |
int |
getBandIndex(String name)
The index of a RasterBand given its name. |
IEnumRasterBand |
getBands()
All the bands in the collection as an interface to the RasterBands enumerator object. |
int |
getBlockHeight()
The native block height. |
int |
getBlockWidth()
The native block width. |
String |
getBrowseName()
The browse name of the dataset. |
String |
getCategory()
The category of the dataset. |
static String |
getClsid()
getClsid. |
String |
getCompleteName()
The full path of the RasterDataset. |
String |
getCompressionType()
The compression technique applied to this RasterDataset. |
int |
getCount()
The number of bands in the collection. |
IEnvelope |
getExtent()
The extent of the GeoDataset. |
int |
getFirstPyramidLevel()
The first available pyramid level. |
String |
getFormat()
The format of this RasterRataset. |
IName |
getFullName()
The associated name object. |
IRasterLODInfos |
getLODInfos()
The custom LOD infos. |
int |
getMaximumPyramidLevel()
The maximum available pyramid level. |
IPropertySet |
getMetadata()
The PropertySet containing metadata. |
IPnt |
getMinimumSize()
The minimum raster pyramid size. |
String |
getName()
The name of the Dataset. |
INativeType |
getNativeType()
The native type. |
IPropertySet |
getPropertySet()
The set of properties for the dataset. |
int |
getPyramidLevel()
The pyramid level. |
int |
getPyramidResamplingMethod()
The pyramid resampling method. |
IRasterInfo |
getRasterInfo()
The raster information. |
String |
getSensorType()
The sensor type used for this RasterDataset. |
ISpatialReference |
getSpatialReference()
The spatial reference of the GeoDataset. |
int |
getStatMode()
The access mode. |
int |
getStatSize()
The size. |
int |
getStatTime(int dateMode)
The date modified/created/accessed. |
int |
getSubdataset()
The current active subdataset. |
int |
getSubdatasetCount()
The number of subdatasets. |
String |
getSubdatasetDescription(int subdatasetID)
The given subdataset description. |
String |
getSubdatasetName(int subdatasetID)
The given subdataset name. |
IEnumDataset |
getSubsets()
Datasets contained within this dataset. |
int |
getType()
The type of the Dataset. |
IWorkspace |
getWorkspace()
The workspace containing this dataset. |
int |
hashCode()
the hashcode for this object |
void |
interfaceSupportsErrorInfo(GUID riid)
interfaceSupportsErrorInfo |
boolean |
isCanAlterAttributeTable()
Indicates if the raster attribute table can be altered. |
boolean |
isCanAlterGeodataXform()
Indicates if the geodata transformation of the dataset can be altered. |
boolean |
isCanAlterSpatialReference()
Indicates if the spatial reference of the dataset can be altered. |
boolean |
isCanEditMetadata()
Indicates if metadata can be edited. |
boolean |
isCanWrite()
Indicates if this RasterDataset is writable. |
boolean |
isEmpty()
Indicates whether the raster dataset is empty. |
boolean |
isPresent()
Indicates whether pyramid layers exist. |
boolean |
isTemporary()
Indicates if the dataset is temporary. |
IRasterBand |
item(int bandIndex)
Returns a RasterBand given its index. |
void |
makePermanent()
Persists this temporary dataset permanent. |
IDataset |
makePermanentAs(String new_name,
IWorkspace workspace,
String format)
Persists this temporary dataset to a new permanent dataset. |
void |
mosaic(IRaster raster,
double tolerance)
Mosaics a Raster into this RasterDataset. |
void |
mosaicBands(IRaster raster,
int start,
double tolerance)
Mosaics a Raster into this RasterDataset at a given starting band index. |
void |
precalculateStats(Object index_list)
Calculates statistics and histograms for specified bands. |
void |
read(IPnt tlc,
IRaster raster,
IPixelBlock pixelBlock)
Reads a block of pixels starting from the top left corner. |
void |
readBlock(int tx,
int ty,
int level,
IPixelBlock pPixelBlock)
Reads a raw pixel block. |
void |
readPyramid(IPnt tlc,
int pyramidLevel,
IRaster raster,
IPixelBlock pixelBlock)
Reads a block of pixels at a given pyramid level. |
void |
refresh()
Refreshes opened RasterDataset. |
void |
remove(int index)
Removes an element from the collection. |
void |
rename(String name)
Renames this Dataset. |
IDataset |
saveAs(String new_name,
IWorkspace worksp,
String format)
Creates a new persistent RasterDataset with the bands in the collection. |
IRasterDataset |
saveAsRasterDataset(String name,
IWorkspace workspace,
String format,
IRasterStorageDef storageDef)
Creates a new persistent Raster Dataset of a given format and specified storage definition. |
void |
setBrowseName(String name)
The browse name of the dataset. |
void |
setMetadata(IPropertySet ppPropertySet)
The PropertySet containing metadata. |
void |
setMinimumSize(IPnt ppVal)
The minimum raster pyramid size. |
void |
setSubdataset(int pSubdatasetID)
The current active subdataset. |
void |
synchronize(int action,
int interval)
Updates metadata with the current properties; may create metadata if it doesn't already exist. |
void |
write()
Creates a World File. |
void |
write(IPnt tlc,
IRaster raster,
int mode,
IPixelBlock pixelBlock)
Writes a block of pixels starting from the top left corner. |
void |
writeBinaryAuxFile()
Create a binary AUX file containing georeferencing and spatial reference. |
void |
writeBlock(int tx,
int ty,
int level,
IPixelBlock pPixelBlock)
Writes a raw pixel block. |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.esri.arcgis.interop.RemoteObjRef |
|---|
getJintegraDispatch, release |
| Constructor Detail |
|---|
public RasterDataset()
throws IOException,
UnknownHostException
IOException - if there are interop problems
UnknownHostException - if there are interop problems
public RasterDataset(Object obj)
throws IOException
RasterDataset theRasterDataset = (RasterDataset) obj;
obj to RasterDataset.
obj - an object returned from ArcGIS Engine or Server
IOException - if there are interop problems| Method Detail |
|---|
public static String getClsid()
public boolean equals(Object o)
equals in class Objectpublic int hashCode()
hashCode in class Object
public String getFormat()
throws IOException,
AutomationException
getFormat in interface IRasterDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public String getSensorType()
throws IOException,
AutomationException
getSensorType in interface IRasterDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public String getCompressionType()
throws IOException,
AutomationException
getCompressionType in interface IRasterDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IRaster createDefaultRaster()
throws IOException,
AutomationException
The CreateDefaultRaster method creates a Raster that has a square cell size and contains only three raster bands if the dataset has more than three bands. The three bands are the default bands used in raster RGB renderer and are determined by the settings for default raster behavior made on the RasterDefaultsEnv object in esriCarto library.
createDefaultRaster in interface IRasterDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean canCopy()
throws IOException,
AutomationException
canCopy in interface IDatasetcanCopy in interface IRasterDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IDataset copy(String copyName,
IWorkspace copyWorkspace)
throws IOException,
AutomationException
copy in interface IDatasetcopy in interface IRasterDatasetcopyName - The copyName (in)copyWorkspace - A reference to a com.esri.arcgis.geodatabase.IWorkspace (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void precalculateStats(Object index_list)
throws IOException,
AutomationException
precalculateStats in interface IRasterDatasetindex_list - A Variant (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public String getCompleteName()
throws IOException,
AutomationException
getCompleteName in interface IRasterDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IRaster createRaster()
throws IOException,
AutomationException
An empty raster means that properties of the Raster are not defined. The width, height, and the number of bands of the raster are all 0. It can not be used before populating pixels to it.
createRaster in interface IRasterDataset2IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IRaster createFullRaster()
throws IOException,
AutomationException
createFullRaster in interface IRasterDataset2IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean isEmpty()
throws IOException,
AutomationException
An empty raster means that properties of the Raster are not defined. The width, height, and the number of bands of the raster are all 0. It can not be used before populating pixels to it.
Co-create a Raster and IRasterDataset2::CreateRaster create an empty raster.
IRasterBandCollection::AppendBands or AppendBand allows you to populate this raster.
isEmpty in interface IRasterDataset2IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getBlockWidth()
throws IOException,
AutomationException
getBlockWidth in interface IRasterDataset3IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getBlockHeight()
throws IOException,
AutomationException
getBlockHeight in interface IRasterDataset3IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getMaximumPyramidLevel()
throws IOException,
AutomationException
getMaximumPyramidLevel in interface IRasterDataset3IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getFirstPyramidLevel()
throws IOException,
AutomationException
getFirstPyramidLevel in interface IRasterDataset3IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IRasterLODInfos getLODInfos()
throws IOException,
AutomationException
getLODInfos in interface IRasterDataset3IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean isCanWrite()
throws IOException,
AutomationException
isCanWrite in interface IRasterDataset3IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void read(IPnt tlc,
IRaster raster,
IPixelBlock pixelBlock)
throws IOException,
AutomationException
read in interface IRasterDataset3tlc - A reference to a com.esri.arcgis.geodatabase.IPnt (in)raster - A reference to a com.esri.arcgis.geodatabase.IRaster (in)pixelBlock - A reference to a com.esri.arcgis.geodatabase.IPixelBlock (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void write(IPnt tlc,
IRaster raster,
int mode,
IPixelBlock pixelBlock)
throws IOException,
AutomationException
write in interface IRasterDataset3tlc - A reference to a com.esri.arcgis.geodatabase.IPnt (in)raster - A reference to a com.esri.arcgis.geodatabase.IRaster (in)mode - A com.esri.arcgis.geodatabase.esriRasterWriteMode constant (in)pixelBlock - A reference to a com.esri.arcgis.geodatabase.IPixelBlock (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void refresh()
throws IOException,
AutomationException
refresh in interface IRasterDataset3IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void readPyramid(IPnt tlc,
int pyramidLevel,
IRaster raster,
IPixelBlock pixelBlock)
throws IOException,
AutomationException
readPyramid in interface IRasterDataset3tlc - A reference to a com.esri.arcgis.geodatabase.IPnt (in)pyramidLevel - The pyramidLevel (in)raster - A reference to a com.esri.arcgis.geodatabase.IRaster (in)pixelBlock - A reference to a com.esri.arcgis.geodatabase.IPixelBlock (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void mosaic(IRaster raster,
double tolerance)
throws IOException,
AutomationException
mosaic in interface IRasterDatasetEditraster - A reference to a com.esri.arcgis.geodatabase.IRaster (in)tolerance - The tolerance (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void mosaicBands(IRaster raster,
int start,
double tolerance)
throws IOException,
AutomationException
This method is supported by RasterDataset instances created from geodatabase and TIFF, Imagine and GRID raster formats.
mosaicBands in interface IRasterDatasetEditraster - A reference to a com.esri.arcgis.geodatabase.IRaster (in)start - The start (in)tolerance - The tolerance (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void erase(IEnvelope extent)
throws IOException,
AutomationException
erase in interface IRasterDatasetEditextent - A reference to a com.esri.arcgis.geometry.IEnvelope (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void computeStats(int pyramidLevel)
throws IOException,
AutomationException
This method is avaliable only on raster datasets in File and ArcSDE geodatabases.
computeStats in interface IRasterDatasetEditpyramidLevel - The pyramidLevel (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void deleteStats()
throws IOException,
AutomationException
This method is avaliable only on raster datasets in File and ArcSDE geodatabases.
deleteStats in interface IRasterDatasetEditIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void alterColormap(IRasterColormap colormap)
throws IOException,
AutomationException
alterColormap in interface IRasterDatasetEditcolormap - A reference to a com.esri.arcgis.geodatabase.IRasterColormap (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void deleteColormap()
throws IOException,
AutomationException
This method only applies to database Rasterdataset , a raster dataset stored in a File or ArcSDE geodatabase.
deleteColormap in interface IRasterDatasetEditIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void appendNewBand()
throws IOException,
AutomationException
This method is available only on a raster dataset in File and ArcSDE geodatabases.
appendNewBand in interface IRasterDatasetEditIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void alterAttributeTable(ITable newTable)
throws IOException,
AutomationException
alterAttributeTable in interface IRasterDatasetEdit2newTable - A reference to a com.esri.arcgis.geodatabase.ITable (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void deleteAttributeTable()
throws IOException,
AutomationException
deleteAttributeTable in interface IRasterDatasetEdit2IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean isCanAlterAttributeTable()
throws IOException,
AutomationException
isCanAlterAttributeTable in interface IRasterDatasetEdit2IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void buildAttributeTable()
throws IOException,
AutomationException
buildAttributeTable in interface IRasterDatasetEdit2IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void computeStatisticsHistogram(int skipx,
int skipy,
Object ignoreValues,
boolean requireHistogram)
throws IOException,
AutomationException
computeStatisticsHistogram in interface IRasterDatasetEdit3skipx - The skipx (in)skipy - The skipy (in)ignoreValues - A Variant (in)requireHistogram - The requireHistogram (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public String getName()
throws IOException,
AutomationException
getName in interface IDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IName getFullName()
throws IOException,
AutomationException
getFullName in interface IDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public String getBrowseName()
throws IOException,
AutomationException
getBrowseName in interface IDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setBrowseName(String name)
throws IOException,
AutomationException
setBrowseName in interface IDatasetname - The name (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getType()
throws IOException,
AutomationException
// Assume we have a reference to an IfeatureClass (pFeatureClass) IDataset pDataset = null;
pDataset = new IDatasetProxy(pFeatureClass);
System.out.println(pDataset.getName() + " " + pDataset.getType());
if(pFeatureClass != null){
pDataset = pFeatureClass.getFeatureDataset();
System.out.println(pDataset.getName() + " " + pDataset.getType());
}
pDataset = new IDatasetProxy(pDataset.getWorkspace());
System.out.println(pDataset.getName() + " " +
pDataset.getType());
getType in interface IDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public String getCategory()
throws IOException,
AutomationException
IDataset::Category returns a description of the category of the dataset. The description returned from the Category property is the same value that is displayed in the Type column within the Contents tab in ArcCatalog. The value will contain a description of the dataset such as "Topology" prefixed with a description of the type of workspace containing the dataset such as "File Geodatabase".
The description returned from IDataset::Category may change between releases of ArcGIS. In addition to this, returned strings are localized, meaning that code relying on a specific string being provided may fail when deployed with a different version of ArcGIS than it was developed with, or when deployed to a client using a different language than it was developed with.
getCategory in interface IDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IEnumDataset getSubsets()
throws IOException,
AutomationException
The Subsets property returns other Dataset objects contained in this dataset.
IDataset::Subsets is not supported for Graph objects such as a Geometric Network. To return the feature classes contained in a Geometric Network, use the IFeatureClassContainer interface.
getSubsets in interface IDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IWorkspace getWorkspace()
throws IOException,
AutomationException
The Workspace property returns the containing workspace for this dataset.
getWorkspace in interface IDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IPropertySet getPropertySet()
throws IOException,
AutomationException
The PropertySet property is used to return any additional intrinsic properties (but not metadata properties) that may apply to the dataset. One use of this property is to distinguish between the types of File Geodatabase datafile formats. If called on a Feature Class or Table in a File Geodatabase the Datafile Format property can either be esriFGDBStandardDatafile or esriFGDBCompressedDatafile.
Most datasets do not implement this property and will either raise an error or return a null value if it's called. There are a handful of exceptions that will return property sets; these include the datasets from file geodatabases (as mentioned above) and coverages.
Examples of intrinsic properties for which explicit methods exist include the SpatialReference and the Extent methods available on the IGeoDataset interface. In most cases this PropertySet will be empty.
IDataset::PropertySet is not supported for Graph objects such as a Geometric Network.
getPropertySet in interface IDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean canDelete()
throws IOException,
AutomationException
The CanCopy, CanDelete, and CanRename properties are meant to be used in conjunction with the Copy, Delete, and Rename methods and signify whether a dataset is supported by these methods. For example, you may not delete a network feature class nor can you use the Copy method on a Geodatabase feature class. To copy Geodatabase datasets, including feature classes, geometric networks, topologies, etc., use the IGeoDBDataTransfer interface.
canDelete in interface IDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void delete()
throws IOException,
AutomationException
Certain feature classes, such as network and topology feature classes, cannot be deleted until their containing objects are deleted.
delete in interface IDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean canRename()
throws IOException,
AutomationException
The CanCopy, CanDelete, and CanRename properties are meant to be used in conjunction with the Copy, Delete, and Rename methods and signify whether a dataset is supported by these methods. For example, you may not delete or rename a network feature class nor can you use the Copy method on a Geodatabase feature class. To copy Geodatabase datasets, including feature classes, geometric networks, topologies, etc., use the IGeoDBDataTransfer interface.
canRename in interface IDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void rename(String name)
throws IOException,
AutomationException
IDataset::Rename does not support the renaming of Graph objects such as a Geometric Network. In addition, certain feature classes, such as network feature classes, cannot be renamed.
rename in interface IDatasetname - The name (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public ISpatialReference getSpatialReference()
throws IOException,
AutomationException
This property is read only. For layers, when the first layer is added to ArcMap, its spatial reference is read by this property, and the map is set to this spatial reference.
Instances of the esriCarto.GroupLayer class will return null for this property, as a group layer can contain multiple datasets with different spatial references.
Modifications to a spatial reference returned by this property will not be persisted. To modify the spatial reference of a dataset, the IGeoDatasetSchemaEdit and IGeoDatasetSchemaEdit2 interfaces should be used.
getSpatialReference in interface IGeoDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IEnvelope getExtent()
throws IOException,
AutomationException
The IGeoDataset::Extent property returns an envelope representing the maximum extent of data which has been stored in the dataset.
Consider the following scenario. A new feature class has features added to it. The IGeoDataset::Extent is then requested and an envelope is returned. The extents of the envelope returned are represented by the red box in the image below.
If a portion of the features were then deleted and the extent is again requested an envelope with the exact same extents as during the first request would be returned (see image below). This is because the deletion of features does not shrink the extent. However all additions of features outside the red box would increase the envelope returned to encompass the newly added features.
If you would like to update the IGeoDataset::Extent property to reflect the current features in your dataset please see IFeatureClassManage::UpdateExtent (also see IFeatureClassLoad). In the image below the extent has been updated and a new envelope is being returned.
ESRI's GroupLayer implements this property differently from most other layer coclasses. When you instantiate a new GroupLayer, this property will return a valid envelope with zero height and width. With most other newly instantiated layers (for example FeatureLayer, RasterLayer, TinLayer), this property initally returns Nothing.
getExtent in interface IGeoDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean isCanAlterSpatialReference()
throws IOException,
AutomationException
isCanAlterSpatialReference in interface IGeoDatasetSchemaEditIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void alterSpatialReference(ISpatialReference spatialReference)
throws IOException,
AutomationException
alterSpatialReference in interface IGeoDatasetSchemaEditspatialReference - A reference to a com.esri.arcgis.geometry.ISpatialReference (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean isCanAlterGeodataXform()
throws IOException,
AutomationException
isCanAlterGeodataXform in interface IGeoDatasetSchemaEdit2IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void alterGeodataXform(IGeodataXform xform)
throws IOException,
AutomationException
alterGeodataXform in interface IGeoDatasetSchemaEdit2xform - A reference to a com.esri.arcgis.geodatabase.IGeodataXform (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void alterResolution(double xyResolution,
double zResolution,
double mResolution)
throws IOException,
AutomationException
AlterResolution will change the resolution of the dataset based on the supplied XY, Z and M resolution values and rebuild the spatial indices. AlterResolution can only be used on Low Precision datasets within a 9.2 Geodatabase. To determine if AlterPrecision can be used on dataset, use the IControlPrecision2::IsHighPrecision property.
Use the IGeoDatasetSchemaEdit2::ConstructResolutions method to obtain the applicable levels of resolution for your data.
If a value of -1 is supplied for the xyResolution or zResolution arguments, the current resolution will be maintained. The current resolution of for a dataset can be obtained from its spatial reference using the ISpatialReferenceResolution interface.
Any of the following scenarios will result in an error:
alterResolution in interface IGeoDatasetSchemaEdit2xyResolution - The xyResolution (in)zResolution - The zResolution (in)mResolution - The mResolution (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void constructResolutions(ISpatialReference spatialReference,
int numberRequested,
int[] defaultXYResolutionIndex,
IDoubleArray[] xyResolutions,
IDoubleArray[] zResolutions,
IDoubleArray[] mResolutions)
throws IOException,
AutomationException
ConstructResolutions should be used to determine the acceptable levels of resolution available for AlterResolution.
constructResolutions in interface IGeoDatasetSchemaEdit2spatialReference - A reference to a com.esri.arcgis.geometry.ISpatialReference (in)numberRequested - The numberRequested (in)defaultXYResolutionIndex - The defaultXYResolutionIndex (out: use single element array)xyResolutions - A reference to a com.esri.arcgis.system.IDoubleArray (out: use single element array)zResolutions - A reference to a com.esri.arcgis.system.IDoubleArray (out: use single element array)mResolutions - A reference to a com.esri.arcgis.system.IDoubleArray (out: use single element array)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void add(IRasterBand element,
int index)
throws IOException,
AutomationException
This method is only applicable to work with a Raster, not with a RasterDataset.
add in interface IRasterBandCollectionelement - A reference to a com.esri.arcgis.datasourcesraster.IRasterBand (in)index - The index (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getCount()
throws IOException,
AutomationException
getCount in interface IRasterBandCollectionIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void clear()
throws IOException,
AutomationException
This method is only applicable to work with a Raster, not with a RasterDataset.
clear in interface IRasterBandCollectionIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void remove(int index)
throws IOException,
AutomationException
This method is only applicable to work with a Raster, not with a RasterDataset.
remove in interface IRasterBandCollectionindex - The index (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getBandIndex(String name)
throws IOException,
AutomationException
getBandIndex in interface IRasterBandCollectionname - The name (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IRasterBand getBandByName(String name)
throws IOException,
AutomationException
getBandByName in interface IRasterBandCollectionname - The name (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IEnumRasterBand getBands()
throws IOException,
AutomationException
getBands in interface IRasterBandCollectionIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IRasterBand item(int bandIndex)
throws IOException,
AutomationException
item in interface IRasterBandCollectionbandIndex - The bandIndex (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IDataset saveAs(String new_name,
IWorkspace worksp,
String format)
throws IOException,
AutomationException
The SaveAs method can create a raster dataset in Imagine, TIFF, GRID, JPEG2000, JPEG, BMP, GIF, PNG, PCI Raster, USGS ASCII DEM, X11 Pixmap, Memory Raster and geodatabase raster.
The format strings used for the supported formats are below, and they are case sensitive:
| Format Name | String Used |
|---|---|
| Imagine | "IMAGINE Image" |
| TIFF | "TIFF" |
| GRID | "GRID" |
| JPEG | "JPG" |
| JP2000 | "JP2" |
| BMP | "BMP" |
| PNG | "PNG" |
| GIF | "GIF" |
| PCI Raster | "PIX" |
| X11 Pixmap | "XPM" |
| PCRaster | "MAP" |
| Memory Raster | "MEM" |
| HDF4 | "HDF4" |
| BIL | "BIL" |
| BIP | "BIP" |
| BSQ | "BSQ" |
| Idrisi Raster Format | "RST" |
| ENVI Raster Format | "ENVI" |
| Geodatabase Raster | "GDB" |
The format string "TIFF" creates a TIFF file with ".tif" extension. ArcGIS also supports TIFF format with ".tiff" and ".tff" extensions. A format string "TIF" creates a TIFF file with ".tiff" extention and a format string "TFF" creates a TIFF file with ".tff" extension.
Note, SaveAs will return a RasterDataset, to prevent from SaveAs holding the output, .NET ReleaseCOMObject needs to be called to release the referene to the output raster dataset:
System.Runtime.InteropServices.Marshal.ReleaseComObject(outRasterDS);
saveAs in interface IRasterBandCollectionsaveAs in interface ISaveAsnew_name - The new_name (in)worksp - A reference to a com.esri.arcgis.geodatabase.IWorkspace (in)format - The format (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void appendBand(IRasterBand element)
throws IOException,
AutomationException
This method is only applicable to work with a Raster, not with a RasterDataset.
appendBand in interface IRasterBandCollectionelement - A reference to a com.esri.arcgis.datasourcesraster.IRasterBand (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void appendBands(IRasterBandCollection bands)
throws IOException,
AutomationException
This method is only applicable to work with a Raster, not with a RasterDataset.
appendBands in interface IRasterBandCollectionbands - A reference to a com.esri.arcgis.datasourcesraster.IRasterBandCollection (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean isPresent()
throws IOException,
AutomationException
isPresent in interface IRasterPyramidIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setMinimumSize(IPnt ppVal)
throws IOException,
AutomationException
setMinimumSize in interface IRasterPyramidppVal - A reference to a com.esri.arcgis.geodatabase.IPnt (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IPnt getMinimumSize()
throws IOException,
AutomationException
getMinimumSize in interface IRasterPyramidIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void create()
throws IOException,
AutomationException
create in interface IRasterPyramidIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getPyramidLevel()
throws IOException,
AutomationException
getPyramidLevel in interface IRasterPyramid2IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getPyramidResamplingMethod()
throws IOException,
AutomationException
getPyramidResamplingMethod in interface IRasterPyramid2IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void buildPyramid(int maxLevel,
int method)
throws IOException,
AutomationException
buildPyramid in interface IRasterPyramid2maxLevel - The maxLevel (in)method - A com.esri.arcgis.geodatabase.rstResamplingTypes constant (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void deletePyramid()
throws IOException,
AutomationException
deletePyramid in interface IRasterPyramid3IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IPropertySet getMetadata()
throws IOException,
AutomationException
The variable to hold the data must be of IPropertySet data type.
The metadata property is frequently used to save, or update, changes to metadata documents that have taken place through methods available on the IPropertySet, IXmlPropertySet, and/or IXmlPropertySet2 interfaces.
getMetadata in interface IMetadataIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setMetadata(IPropertySet ppPropertySet)
throws IOException,
AutomationException
setMetadata in interface IMetadatappPropertySet - A reference to a com.esri.arcgis.system.IPropertySet (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void synchronize(int action,
int interval)
throws IOException,
AutomationException
The Synchronize method is used to extract metadata properties from an object and write those properties to the metadata .xml. Depending on the value of the esriMetaSyncAction, the Synchronize method may generate a new set of metadata if it doesn't already exist.
The following actions will result in synchronization given each of the listed conditions:
| Action | Metadata status | Esri/Sync element | Interval parameter |
|---|---|---|---|
| esriMSAAccessed | Doesn't matter | Must not be FALSE | Must be less than actual interval |
| esriMSAAlways | Doesn't matter | Doesn't matter | Doesn't matter |
| esriMSACreated | Must not exist | Must not be FALSE | Must be less than actual interval |
| esriMSANotCreated | Must exist | Must not be FALSE | Must be less than actual interval |
| esriMSAOverwrite | Doesn't matter | Doesn't matter | Doesn't matter |
The difference between esriMSAAlways and esriMSAOverwrite lies in which elements are synchronized. esriMSAAlways will honor the removal or value change of an element's Sync attribute (to disable synchronization), whereas using esriMSAOverwrite is equivalent to setting the IXmlPropertySet2.OverwriteSyncAttribute to true for the metadata's property set, meaning that even elements without a Sync attribute of TRUE will be synchronized.
synchronize in interface IMetadataaction - A com.esri.arcgis.geodatabase.esriMetadataSyncAction constant (in)interval - The interval (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean isCanEditMetadata()
throws IOException,
AutomationException
This property is available to those objects that support metadata.
isCanEditMetadata in interface IMetadataEditIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public INativeType getNativeType()
throws IOException,
AutomationException
getNativeType in interface INativeTypeInfoIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean isTemporary()
throws IOException,
AutomationException
isTemporary in interface ITemporaryDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void makePermanent()
throws IOException,
AutomationException
makePermanent in interface ITemporaryDatasetIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IDataset makePermanentAs(String new_name,
IWorkspace workspace,
String format)
throws IOException,
AutomationException
makePermanentAs in interface ITemporaryDatasetnew_name - The new_name (in)workspace - A reference to a com.esri.arcgis.geodatabase.IWorkspace (in)format - The format (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void analyze(int tableComponents)
throws IOException,
AutomationException
When applied to a feature dataset, Analyze updates the statistics for all of the tables.
analyze in interface IDatasetAnalyzetableComponents - The tableComponents (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getAllowableComponents()
throws IOException,
AutomationException
The AllowableComponents property indicates which parts of the table or feature class can be analyzed. The returned value is based on the esriTableComponents enumeration. Members from this enumeration can be bitwise or’d together.
getAllowableComponents in interface IDatasetAnalyzeIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getStatTime(int dateMode)
throws IOException,
AutomationException
getStatTime in interface IDatasetFileStatdateMode - A com.esri.arcgis.geodatabase.esriDatasetFileStatTimeMode constant (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getStatSize()
throws IOException,
AutomationException
getStatSize in interface IDatasetFileStatIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getStatMode()
throws IOException,
AutomationException
getStatMode in interface IDatasetFileStatIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void interfaceSupportsErrorInfo(GUID riid)
throws IOException,
AutomationException
Indicates whether the interface supports IErrorInfo.
interfaceSupportsErrorInfo in interface ISupportErrorInforiid - A Structure: com.esri.arcgis.support.ms.stdole.GUID (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void write()
throws IOException,
AutomationException
For GRID format or datasets that get their georeference information from a world file, IWorldFileExport:Write method has no effect.
write in interface IWorldFileExportIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void writeBinaryAuxFile()
throws IOException,
AutomationException
writeBinaryAuxFile in interface IWorldFileExport2IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getSubdatasetCount()
throws IOException,
AutomationException
getSubdatasetCount in interface IRasterDatasetJukeboxIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getSubdataset()
throws IOException,
AutomationException
This property is used to get/set the index of a subdataset which becomes the current raster dataset
getSubdataset in interface IRasterDatasetJukeboxIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setSubdataset(int pSubdatasetID)
throws IOException,
AutomationException
setSubdataset in interface IRasterDatasetJukeboxpSubdatasetID - The pSubdatasetID (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public String getSubdatasetName(int subdatasetID)
throws IOException,
AutomationException
getSubdatasetName in interface IRasterDatasetJukeboxsubdatasetID - The subdatasetID (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public String getSubdatasetDescription(int subdatasetID)
throws IOException,
AutomationException
getSubdatasetDescription in interface IRasterDatasetJukeboxsubdatasetID - The subdatasetID (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public boolean canSaveAs(String format)
throws IOException,
AutomationException
canSaveAs in interface ISaveAsformat - The format (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IRasterDataset saveAsRasterDataset(String name,
IWorkspace workspace,
String format,
IRasterStorageDef storageDef)
throws IOException,
AutomationException
The pStorageDef argument specified the storage parameters, compression type, compression quality, tile size, ect. The parameters apply to certain output raster format, if the output raster format doesn't support the storage parameter specified, the settings are ignored.
The format strings used for the supported formats are below, and they are case sensitive:
| Format Name | String Used |
|---|---|
| Imagine | "IMAGINE Image" |
| TIFF | "TIFF" |
| GRID | "GRID" |
| JPEG | "JPG" |
| JP2000 | "JP2" |
| BMP | "BMP" |
| PNG | "PNG" |
| GIF | "GIF" |
| PCI Raster | "PIX" |
| X11 Pixmap | "XPM" |
| PCRaster | "MAP" |
| Memory Raster | "MEM" |
| HDF4 | "HDF4" |
| BIL | "BIL" |
| BIP | "BIP" |
| BSQ | "BSQ" |
| Idrisi Raster Format | "RST" |
| ENVI Raster Format | "ENVI" |
| Geodatabase Raster | "GDB" |
saveAsRasterDataset in interface ISaveAs2name - The name (in)workspace - A reference to a com.esri.arcgis.geodatabase.IWorkspace (in)format - The format (in)storageDef - A reference to a com.esri.arcgis.geodatabase.IRasterStorageDef (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IRasterInfo getRasterInfo()
throws IOException,
AutomationException
getRasterInfo in interface IRawBlocksIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IPixelBlock createPixelBlock()
throws IOException,
AutomationException
createPixelBlock in interface IRawBlocksIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void readBlock(int tx,
int ty,
int level,
IPixelBlock pPixelBlock)
throws IOException,
AutomationException
readBlock in interface IRawBlockstx - The tx (in)ty - The ty (in)level - The level (in)pPixelBlock - A reference to a com.esri.arcgis.geodatabase.IPixelBlock (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void writeBlock(int tx,
int ty,
int level,
IPixelBlock pPixelBlock)
throws IOException,
AutomationException
writeBlock in interface IRawBlockstx - The tx (in)ty - The ty (in)level - The level (in)pPixelBlock - A reference to a com.esri.arcgis.geodatabase.IPixelBlock (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void flush()
throws IOException,
AutomationException
flush in interface IRawBlocksIOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||