|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.esri.arcgis.arcmapui.SpatialJoin
public class SpatialJoin
Spatial Join two feature classes.
A spatial join is a form of spatial analysis in which the attributes of features in two feature classes are joined together based on the relative locations of the features. Spatial joins are not dynamic and require the results to be saved to a new output layer.
| Constructor Summary | |
|---|---|
SpatialJoin()
Constructs a SpatialJoin using ArcGIS Engine. |
|
SpatialJoin(Object obj)
Deprecated. As of ArcGIS 9.2, replaced by normal Java casts. SpatialJoin theSpatialJoin = (SpatialJoin) obj; |
|
| Method Summary | |
|---|---|
boolean |
equals(Object o)
Compare this object with another |
static String |
getClsid()
getClsid. |
int |
hashCode()
the hashcode for this object |
IFeatureClass |
joinAggregate(IName pOutputName,
double maxMapDist)
Join using aggregate. |
IFeatureClass |
joinNearest(IName pOutputName,
double maxMapDist)
Joins with the nearest feature in the join feature class. |
IFeatureClass |
joinWithin(IName pOutputName)
Joins a feature in the source feature class with the feature if it falls within in the join feature class. |
void |
setIsAverage(boolean rhs1)
Indicates if the average of all numeric fields in the join feature class is appended to the result. |
void |
setIsCount(boolean rhs1)
Indicates if the count of all numeric fields in the join feature class is appended to the result. |
void |
setIsMax(boolean rhs1)
Indicates if the maximum of all numeric fields in the join feature class is appended to the result. |
void |
setIsMin(boolean rhs1)
Indicates if the minimum of all numeric fields in the join feature class is appended to the result. |
void |
setIsStdDev(boolean rhs1)
Indicates if the standard deviation of all numeric fields in the join feature class is appended to the result. |
void |
setIsSum(boolean rhs1)
Indicates if the sum of all numeric fields in the join feature class is appended to the result. |
void |
setIsVar(boolean rhs1)
Indicates if the variance of all numeric fields in the join feature class is appended to the result. |
void |
setJoinTableByRef(ITable rhs1)
The spatial table to append fields from. |
void |
setLeftOuterJoin(boolean rhs1)
Indicates whether a match is required before adding a record from the source feature class to the result. |
void |
setShowProcess(boolean bShowMessage,
int rhs2)
Indicates whether to show update messages while processing join. |
void |
setSourceTableByRef(ITable rhs1)
The spatial table to append fields to. |
| 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 SpatialJoin()
throws IOException,
UnknownHostException
IOException - if there are interop problems
UnknownHostException - if there are interop problems
public SpatialJoin(Object obj)
throws IOException
SpatialJoin theSpatialJoin = (SpatialJoin) obj;
obj to SpatialJoin.
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 void setSourceTableByRef(ITable rhs1)
throws IOException,
AutomationException
setSourceTableByRef in interface ISpatialJoinrhs1 - 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 setJoinTableByRef(ITable rhs1)
throws IOException,
AutomationException
setJoinTableByRef in interface ISpatialJoinrhs1 - 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 IFeatureClass joinAggregate(IName pOutputName,
double maxMapDist)
throws IOException,
AutomationException
JoinAggregate will count the number of features in the join table that are the closest to features in the source table. The maxMapDist parameter determines the search radius for the join operation. Negative maxMapDist values other than -1 (infinity) are invalid and will produce an empty output feature class.
For example, if a source layer containing line features (rivers) is spatially joined to a layer which contains point features (cities), the new output layer will contain a record for each feature in the source table and include an additional column, 'count'. Where a match was successful, the value in this column indicates the number of cities closest to a particular river, given the value of maxMapDist.
Rivers and cities feature classes:

Output feature class table:

If additional information about the related features is required, QI on the SpatialJoin CoClass for the IAggregateOptions interface to append an aggregate (minimium, average, maximum etc.) of the numeric attributes of the closest features.
Output feature class table with aggregated numeric attributes:

joinAggregate in interface ISpatialJoinpOutputName - A reference to a com.esri.arcgis.system.IName (in)maxMapDist - The maxMapDist (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IFeatureClass joinNearest(IName pOutputName,
double maxMapDist)
throws IOException,
AutomationException
JoinNearest identifies the nearest feature in the join table to features in the source table. The maxMapDist parameter determines the search radius for the join operation. Negative maxMapDist values other than -1 (infinity) are invalid and will produce an empty output feature class.
For example, joining a source layer containing line features (rivers) to a layer which contains point features (cities) with LeftOuterJoin = FALSE. Where a match is successful, the new output layer will contain a record for each feature in the source table with the corresponding attribute columns for the nearest feature in the join table.
Rivers and cities feature classes:

New output feature class table:
joinNearest in interface ISpatialJoinpOutputName - A reference to a com.esri.arcgis.system.IName (in)maxMapDist - The maxMapDist (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IFeatureClass joinWithin(IName pOutputName)
throws IOException,
AutomationException
JoinWithin identifies those features in the source table that are contained by features in the table being joined.
For example, if the source layer containing line features (rivers) is spatially joined to a layer which contains polygon features (administrative boundaries), with the LeftOuterJoin property set to TRUE, the new output layer will contain a record for each feature in the source table with all the attribute columns from the join table appended. Where a JoinWithin match was identified, each river in the new feature class will now have additional attribute information about the administrative boundary it falls within. Where no match was identified, the appended columns will be empty.
River and states feature classes:

New feature class table:
joinWithin in interface ISpatialJoinpOutputName - A reference to a com.esri.arcgis.system.IName (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setShowProcess(boolean bShowMessage,
int rhs2)
throws IOException,
AutomationException
setShowProcess in interface ISpatialJoinbShowMessage - The bShowMessage (in)rhs2 - The rhs2 (A COM typedef) (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setLeftOuterJoin(boolean rhs1)
throws IOException,
AutomationException
The following diagram illustrates the nature of the join which is performed depending on whether this parameter is set to true or false:

setLeftOuterJoin in interface ISpatialJoinrhs1 - The rhs1 (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setIsSum(boolean rhs1)
throws IOException,
AutomationException
setIsSum in interface IAggregateOptionsrhs1 - The rhs1 (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setIsAverage(boolean rhs1)
throws IOException,
AutomationException
setIsAverage in interface IAggregateOptionsrhs1 - The rhs1 (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setIsCount(boolean rhs1)
throws IOException,
AutomationException
setIsCount in interface IAggregateOptionsrhs1 - The rhs1 (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setIsMax(boolean rhs1)
throws IOException,
AutomationException
setIsMax in interface IAggregateOptionsrhs1 - The rhs1 (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setIsMin(boolean rhs1)
throws IOException,
AutomationException
setIsMin in interface IAggregateOptionsrhs1 - The rhs1 (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setIsStdDev(boolean rhs1)
throws IOException,
AutomationException
setIsStdDev in interface IAggregateOptionsrhs1 - The rhs1 (in)
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setIsVar(boolean rhs1)
throws IOException,
AutomationException
setIsVar in interface IAggregateOptionsrhs1 - The rhs1 (in)
IOException - 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 | ||||||||