|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.esri.arcgis.geoprocessing.AbstractGPTool com.esri.arcgis.geoprocessing.tools.networkanalysttools.AddLocations
public class AddLocations
Adds network analysis objects to a network analysis layer. The objects are added to specific sublayers such as Stops and Barriers. Objects are input as features or records. The Add Locations tool is contained in the Network Analyst Tools tool box.
Field Summary |
---|
Fields inherited from class com.esri.arcgis.geoprocessing.AbstractGPTool |
---|
vals |
Constructor Summary | |
---|---|
AddLocations()
Creates the Add Locations tool with defaults. |
|
AddLocations(Object inNetworkAnalysisLayer,
String subLayer,
Object inTable,
Object fieldMappings,
Object searchTolerance)
Creates the Add Locations tool with the required parameters. |
Method Summary | |
---|---|
String |
getAppend()
Returns the Append to existing locations parameter of this tool . |
String |
getExcludeRestrictedElements()
Returns the Exclude restricted portions of the network parameter of this tool . |
Object |
getFieldMappings()
Returns the Field mappings parameter of this tool . |
Object |
getInNetworkAnalysisLayer()
Returns the Input network analysis layer parameter of this tool . |
Object |
getInTable()
Returns the Input locations parameter of this tool . |
String |
getMatchType()
Returns the Find closest among all classes parameter of this tool . |
Object |
getOutputLayer()
Returns the Network Analyst Layer parameter of this tool (Read only). |
Object |
getSearchCriteria()
Returns the Search criteria parameter of this tool . |
Object |
getSearchQuery()
Returns the Search query parameter of this tool . |
Object |
getSearchTolerance()
Returns the Search tolerance parameter of this tool . |
Object |
getSnapOffset()
Returns the Snap Offset parameter of this tool . |
String |
getSnapToPositionAlongNetwork()
Returns the Snap to Network parameter of this tool . |
Object |
getSortField()
Returns the Sort field parameter of this tool . |
String |
getSubLayer()
Returns the Sub layer parameter of this tool . |
String |
getToolboxAlias()
Returns the alias of the tool box containing this tool. |
String |
getToolboxName()
Returns the name of the tool box containing this tool. |
String |
getToolName()
Returns the name of this tool. |
void |
setAppend(String append)
Sets the Append to existing locations parameter of this tool . |
void |
setExcludeRestrictedElements(String excludeRestrictedElements)
Sets the Exclude restricted portions of the network parameter of this tool . |
void |
setFieldMappings(Object fieldMappings)
Sets the Field mappings parameter of this tool . |
void |
setInNetworkAnalysisLayer(Object inNetworkAnalysisLayer)
Sets the Input network analysis layer parameter of this tool . |
void |
setInTable(Object inTable)
Sets the Input locations parameter of this tool . |
void |
setMatchType(String matchType)
Sets the Find closest among all classes parameter of this tool . |
void |
setSearchCriteria(Object searchCriteria)
Sets the Search criteria parameter of this tool . |
void |
setSearchQuery(Object searchQuery)
Sets the Search query parameter of this tool . |
void |
setSearchTolerance(Object searchTolerance)
Sets the Search tolerance parameter of this tool . |
void |
setSnapOffset(Object snapOffset)
Sets the Snap Offset parameter of this tool . |
void |
setSnapToPositionAlongNetwork(String snapToPositionAlongNetwork)
Sets the Snap to Network parameter of this tool . |
void |
setSortField(Object sortField)
Sets the Sort field parameter of this tool . |
void |
setSubLayer(String subLayer)
Sets the Sub layer parameter of this tool . |
Methods inherited from class com.esri.arcgis.geoprocessing.AbstractGPTool |
---|
getParameterValues, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public AddLocations()
Initializes the array of tool parameters with the default values specified when the tool was created.
public AddLocations(Object inNetworkAnalysisLayer, String subLayer, Object inTable, Object fieldMappings, Object searchTolerance)
Initializes the array of tool parameters with the values as specified for the required parameters and with the default values for the other parameters.
inNetworkAnalysisLayer
- network analysis layer to which the network analysis objects will be added.subLayer
- the sublayer of the network analysis layer to which the network analysis objects will be added.inTable
- the feature class or the table that is the source for the new network analysis objects.fieldMappings
- sets the values for the properties of the network analysis objects. Properties can be set to a constant or mapped to a field from the input feature class or table. the parameter value is specified as a semicolon-separated list of three values made up of the property name, the field name, and the default value. You should specify either the field name or the default value for a property. For example, the parameter value "Name Address #; Attr_Minutes # 2", specifies that the Name property is mapped from the Address field and the Attr_Minutes property should have a constant value of 2 when adding your input features. if a particular property is not mapped to a field or has a default value or is not included in the parameter value, it will have the default mapping. If you want to use the default mappings for all the properties, use # for the parameter value. if both the Field and the Default Value are not specified for a property, the resulting network analysis objects will have null values for that property. if the data you are loading contains network locations or location ranges based on the network dataset used for the analysis, map the network location fields from your input features to the network location properties. For point locations such as Stops or Incidents, map the SourceID, SourceOID, PosAlong and SideOfEdge properties and for line or polygon locations such as Polygon Barriers, map the Locations property. Adding the network analysis objects using the network location fields is much faster than loading them by geometry. Specifying the network location fields in the field mappings is similar to using the Use Network Location fields instead of geometry parameter from the tool dialog . if you specify the field mapping for any of the network location properties, you need to specify the field mappings for the remaining network location properties to avoid a tool execution error.searchTolerance
- the search tolerance for locating the input features on the network. Features that are outside the search tolerance are left unlocated. The parameter includes a value and units for the tolerance. the parameter is not used when adding locations to the Line Barriers or Polygon Barriers sublayers. In such cases, use "#" as the parameter value.Method Detail |
---|
public Object getInNetworkAnalysisLayer()
public void setInNetworkAnalysisLayer(Object inNetworkAnalysisLayer)
inNetworkAnalysisLayer
- network analysis layer to which the network analysis objects will be added.public String getSubLayer()
public void setSubLayer(String subLayer)
subLayer
- the sublayer of the network analysis layer to which the network analysis objects will be added.public Object getInTable()
public void setInTable(Object inTable)
inTable
- the feature class or the table that is the source for the new network analysis objects.public Object getFieldMappings()
public void setFieldMappings(Object fieldMappings)
fieldMappings
- sets the values for the properties of the network analysis objects. Properties can be set to a constant or mapped to a field from the input feature class or table. the parameter value is specified as a semicolon-separated list of three values made up of the property name, the field name, and the default value. You should specify either the field name or the default value for a property. For example, the parameter value "Name Address #; Attr_Minutes # 2", specifies that the Name property is mapped from the Address field and the Attr_Minutes property should have a constant value of 2 when adding your input features. if a particular property is not mapped to a field or has a default value or is not included in the parameter value, it will have the default mapping. If you want to use the default mappings for all the properties, use # for the parameter value. if both the Field and the Default Value are not specified for a property, the resulting network analysis objects will have null values for that property. if the data you are loading contains network locations or location ranges based on the network dataset used for the analysis, map the network location fields from your input features to the network location properties. For point locations such as Stops or Incidents, map the SourceID, SourceOID, PosAlong and SideOfEdge properties and for line or polygon locations such as Polygon Barriers, map the Locations property. Adding the network analysis objects using the network location fields is much faster than loading them by geometry. Specifying the network location fields in the field mappings is similar to using the Use Network Location fields instead of geometry parameter from the tool dialog . if you specify the field mapping for any of the network location properties, you need to specify the field mappings for the remaining network location properties to avoid a tool execution error.public Object getSearchTolerance()
public void setSearchTolerance(Object searchTolerance)
searchTolerance
- the search tolerance for locating the input features on the network. Features that are outside the search tolerance are left unlocated. The parameter includes a value and units for the tolerance. the parameter is not used when adding locations to the Line Barriers or Polygon Barriers sublayers. In such cases, use "#" as the parameter value.public Object getSortField()
public void setSortField(Object sortField)
sortField
- a field on which the network analysis objects are sorted as they are added to the network analysis layer. The default is the ObjectID field on the input feature class or the table.public Object getSearchCriteria()
public void setSearchCriteria(Object searchCriteria)
searchCriteria
- specifies which sources in the network dataset will be searched when finding locations and what portions of geometry (also known as snap types) will be used. the parameter value is specified as a list with nested lists. The nested list is made up of two values indicating the name and the snap type for each network source. The snap type is specified using the "SHAPE", "MIDDLE", "END" ,or "NONE" keywords. For example, when finding locations, the parameter value [["Streets","SHAPE"],["Streets_ND_Junctions","NONE"]] specifies that the search can locate on the shape of the Streets source but not on the Streets_ND_Junctions source. to specify multiple snap types for a single network source, use the combination of the snap type keywords separate by an underscore. For example, MIDDLE_END specifies that the locations can be snapped to the middle or end of the network source. when adding line or polygon network locations, only the Shape snap type is used even if other snap types are specified.public String getMatchType()
public void setMatchType(String matchType)
matchType
- the parameter is not used when adding locations to the Line Barriers or Polygon Barriers sublayers. In such cases, use "#" as the parameter value.public String getAppend()
public void setAppend(String append)
append
- specifies whether or not to append new network analysis objects to existing objects.public String getSnapToPositionAlongNetwork()
public void setSnapToPositionAlongNetwork(String snapToPositionAlongNetwork)
snapToPositionAlongNetwork
- specifies that you want to snap the network locations along the network dataset or at some specified offset from the network dataset. the parameter is not used when adding locations to the Line Barriers or Polygon Barriers sublayers. In such cases, use "#" as the parameter value.public Object getSnapOffset()
public void setSnapOffset(Object snapOffset)
snapOffset
- when snapping a point to the network, you can apply an offset distance. An offset distance of zero means the point will be coincident with the network feature (typically a line). To offset the point from the network feature, enter an offset distance. The offset is in relation to the original point location. That is, if the original point was on the left side, its new location will be offset to the left. If it was originally on the right side, its new location will be offset to the right. the parameter is not used when adding locations to the Line Barriers or Polygon Barriers sublayers. In such cases, use "#" as the parameter value.public String getExcludeRestrictedElements()
public void setExcludeRestrictedElements(String excludeRestrictedElements)
excludeRestrictedElements
- nullpublic Object getSearchQuery()
public void setSearchQuery(Object searchQuery)
searchQuery
- specifies a query to restrict the search to a subset of the features within a source feature class. This is useful if you don't want to find features that may be unsuited for a network location. For example, if you are loading centroids of polygons and don't want to locate on local roads, you can define a query that searches for major roads only. the parameter value is specified as a list with nested lists. The nested list is made up of two values indicating the name and the SQL expression for all of the network sources. The syntax for the SQL expression differs slightly depending on the
type of the network source feature class. For example, if
you're querying source feature classes stored in file or ArcSDE geodatabases, shapefiles, or
SDC, enclose field names in double quotes: "CFCC". If you're
querying source feature classes stored in personal geodatabases, enclose fields in square
brackets: [CFCC]. if you don't want to specify a query for a particular source, use "#" as the value for the SQL expression or exclude the source name and the SQL expression from the parameter value. If you don't want to specify a query for all of the network sources, use "#" as the parameter value. for example, the parameter value [["Streets","\"CFCC\" = 'A15'"], ["Streets_ND_Junctions",""]] specifies a SQL expression for the Streets source feature class and no expression for Streets_ND_Junctions source feature class. Note that the double quotes used to enclose the field name CFCC are escaped using back slash characters to avoid a parsing error from the Python interpreter.public Object getOutputLayer()
public String getToolName()
public String getToolboxName()
public String getToolboxAlias()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |