com.esri.arcgis.geodatabase
Interface INetworkAttribute

All Superinterfaces:
java.io.Serializable
All Known Subinterfaces:
IEvaluatedNetworkAttribute, INetworkAttribute2
All Known Implementing Classes:
EvaluatedNetworkAttribute, IEvaluatedNetworkAttributeProxy, INetworkAttribute2Proxy, INetworkAttributeProxy, NetworkAttribute, SDCNetworkAttribute

public interface INetworkAttribute
extends java.io.Serializable

Provides access to members that specify the properties of an attribute in a network dataset.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Remarks

The INetworkAttribute and INetworkAttribute2 interfaces are used to access the properties of the network attribute, such as its name and usage type.

To access the NetworkAttribute or EvaluatedNetworkAttribute object for an existing network dataset attribute, use the Attribute, AttributeByID, or AttributeByName methods on the INetworkDataset interface.

The INetworkAttribute and INetworkAttribute2 interfaces are also used to define a new network attribute.  To create a new network attribute, cocreate a NetworkAttribute or EvaluatedNetworkAttribute object, specify its properties, and pass the object to the INetworkBuild::AddAttribute method on the network dataset.


Method Summary
 int getDataType()
          Type of data used in this network attribute.
 int getID()
          Unique identifier of this network attribute.
 java.lang.String getName()
          Name of this network attribute.
 int getUnits()
          Units of this network attribute.
 int getUsageType()
          Usage type of this network attribute.
 void setDataType(int dataType)
          Type of data used in this network attribute.
 void setName(java.lang.String attributeName)
          Name of this network attribute.
 void setUnits(int units)
          Units of this network attribute.
 void setUsageType(int usageType)
          Usage type of this network attribute.
 

Method Detail

getName

public java.lang.String getName()
                         throws java.io.IOException,
                                AutomationException
Name of this network attribute.

Returns:
The attributeName
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setName

public void setName(java.lang.String attributeName)
             throws java.io.IOException,
                    AutomationException
Name of this network attribute.

Parameters:
attributeName - The attributeName (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getID

public int getID()
          throws java.io.IOException,
                 AutomationException
Unique identifier of this network attribute.

Returns:
The attributeID
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getDataType

public int getDataType()
                throws java.io.IOException,
                       AutomationException
Type of data used in this network attribute.

Remarks

The DataType for the network attribute can be either Integer, Float, Double, or Boolean.

Depending on the UsageType for the network attribute, only certain DataTypes are allowed:

UsageType: Allowed DataTypes:
esriNAUTCost esriNADTInteger, esriNADTFloat, esriNADTDouble
esriNAUTDescriptor esriNADTInteger, esriNADTFloat, esriNADTDouble, esriNADTBoolean
esriNAUTRestriction esriNADTBoolean
esriNAUTHierarchy esriNADTInteger

Returns:
A com.esri.arcgis.geodatabase.esriNetworkAttributeDataType constant
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setDataType

public void setDataType(int dataType)
                 throws java.io.IOException,
                        AutomationException
Type of data used in this network attribute.

Parameters:
dataType - A com.esri.arcgis.geodatabase.esriNetworkAttributeDataType constant (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getUsageType

public int getUsageType()
                 throws java.io.IOException,
                        AutomationException
Usage type of this network attribute.

Remarks

The UsageType for the network attribute can be either Cost, Descriptor, Restriction, or Hierarchy.

Depending on the UsageType for the network attribute, only certain DataTypes are allowed:

UsageType: Allowed DataTypes:
esriNAUTCost esriNADTInteger, esriNADTFloat, esriNADTDouble
esriNAUTDescriptor esriNADTInteger, esriNADTFloat, esriNADTDouble, esriNADTBoolean
esriNAUTRestriction esriNADTBoolean
esriNAUTHierarchy esriNADTInteger

Returns:
A com.esri.arcgis.geodatabase.esriNetworkAttributeUsageType constant
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setUsageType

public void setUsageType(int usageType)
                  throws java.io.IOException,
                         AutomationException
Usage type of this network attribute.

Parameters:
usageType - A com.esri.arcgis.geodatabase.esriNetworkAttributeUsageType constant (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getUnits

public int getUnits()
             throws java.io.IOException,
                    AutomationException
Units of this network attribute.

Remarks

If the attribute is not measured in units of distance or time, specify the Units as esriNAUUnknown.

Returns:
A com.esri.arcgis.geodatabase.esriNetworkAttributeUnits constant
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setUnits

public void setUnits(int units)
              throws java.io.IOException,
                     AutomationException
Units of this network attribute.

Parameters:
units - A com.esri.arcgis.geodatabase.esriNetworkAttributeUnits constant (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.