com.esri.arcgis.geoprocessing
Interface IMdElement

All Superinterfaces:
Serializable
All Known Implementing Classes:
MdProcess, MdVariable

public interface IMdElement
extends Serializable

Provides access to properties/methods of a model element.

Remarks

The IMdElement provides access to model element's properties such as State and Valid, and its methods such as GetMessages and Validate.

MdElement objects are the items that define the contents of a model. A Model Process [IMdProcess] represents the invocation of a tool with its set of values. A Moel Variable [IMdVariable] represents a specific value that is used as input or output of one or more model processes.

The attached sample code show how to access a model process.

Product Availability

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

Supported Platforms

Windows


Method Summary
 IEnumMdElement getDependents(int direction, int connectionType)
          Returns an enumeration of model elements that are dependent on the model element in the given direction and of the given connection type.
 int getID()
          Unique identifier of the model element.
 IGPMessages getMessages()
          Returns the messages returned from the last call to Validate().
 IMdModel getModel()
          The model the model element is contained within.
 String getName()
          Name of the model element.
 int getState()
          The state of the model element.
 boolean isAltered()
          Indicates if the model element has been altered by the user.
 boolean isCurrent()
          Indicates if the model element is current (i.e., has been created).
 boolean isDependentOn(IMdElement pMdElement, int direction, int connectionType)
          Returns whether or not the model element is dependent on the given model element in the given direction of the given connection type.
 boolean isMarked()
          Indicates if the model element has been marked for validation/execution.
 boolean isValid()
          Indicates if the model element is valid.
 void setAltered(boolean altered)
          Indicates if the model element has been altered by the user.
 void setCurrent(boolean current)
          Indicates if the model element is current (i.e., has been created).
 void setID(int identifier)
          Unique identifier of the model element.
 void setMarked(boolean marked)
          Indicates if the model element has been marked for validation/execution.
 void setModelByRef(IMdModel model)
          The model the model element is contained within.
 void setName(String name)
          Name of the model element.
 void setValid(boolean valid)
          Indicates if the model element is valid.
 IGPMessages validate(boolean updateValues, IGPEnvironmentManager pEnvMgr)
          Validates the model element.
 

Method Detail

getID

int getID()
          throws IOException,
                 AutomationException
Unique identifier of the model element.

Product Availability

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

Supported Platforms

Windows

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

setID

void setID(int identifier)
           throws IOException,
                  AutomationException
Unique identifier of the model element.

Product Availability

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

Supported Platforms

Windows

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

getName

String getName()
               throws IOException,
                      AutomationException
Name of the model element.

Product Availability

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

Supported Platforms

Windows

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

setName

void setName(String name)
             throws IOException,
                    AutomationException
Name of the model element.

Product Availability

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

Supported Platforms

Windows

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

isMarked

boolean isMarked()
                 throws IOException,
                        AutomationException
Indicates if the model element has been marked for validation/execution.

Product Availability

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

Supported Platforms

Windows

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

setMarked

void setMarked(boolean marked)
               throws IOException,
                      AutomationException
Indicates if the model element has been marked for validation/execution.

Product Availability

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

Supported Platforms

Windows

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

isCurrent

boolean isCurrent()
                  throws IOException,
                         AutomationException
Indicates if the model element is current (i.e., has been created).

Product Availability

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

Supported Platforms

Windows

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

setCurrent

void setCurrent(boolean current)
                throws IOException,
                       AutomationException
Indicates if the model element is current (i.e., has been created).

Product Availability

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

Supported Platforms

Windows

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

isValid

boolean isValid()
                throws IOException,
                       AutomationException
Indicates if the model element is valid.

Product Availability

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

Supported Platforms

Windows

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

setValid

void setValid(boolean valid)
              throws IOException,
                     AutomationException
Indicates if the model element is valid.

Product Availability

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

Supported Platforms

Windows

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

getModel

IMdModel getModel()
                  throws IOException,
                         AutomationException
The model the model element is contained within.

Product Availability

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

Supported Platforms

Windows

Returns:
A reference to a com.esri.arcgis.geoprocessing.IMdModel
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setModelByRef

void setModelByRef(IMdModel model)
                   throws IOException,
                          AutomationException
The model the model element is contained within.

Product Availability

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

Parameters:
model - A reference to a com.esri.arcgis.geoprocessing.IMdModel (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getState

int getState()
             throws IOException,
                    AutomationException
The state of the model element.

Product Availability

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

Supported Platforms

Windows

Returns:
A com.esri.arcgis.geoprocessing.esriMdElementState constant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getDependents

IEnumMdElement getDependents(int direction,
                             int connectionType)
                             throws IOException,
                                    AutomationException
Returns an enumeration of model elements that are dependent on the model element in the given direction and of the given connection type.

Product Availability

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

Supported Platforms

Windows

Parameters:
direction - A com.esri.arcgis.geoprocessing.esriMdDirection constant (in)
connectionType - A com.esri.arcgis.geoprocessing.esriMdConnectionType constant (in)
Returns:
A reference to a com.esri.arcgis.geoprocessing.IEnumMdElement
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isDependentOn

boolean isDependentOn(IMdElement pMdElement,
                      int direction,
                      int connectionType)
                      throws IOException,
                             AutomationException
Returns whether or not the model element is dependent on the given model element in the given direction of the given connection type.

Product Availability

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

Supported Platforms

Windows

Parameters:
pMdElement - A reference to a com.esri.arcgis.geoprocessing.IMdElement (in)
direction - A com.esri.arcgis.geoprocessing.esriMdDirection constant (in)
connectionType - A com.esri.arcgis.geoprocessing.esriMdConnectionType constant (in)
Returns:
The pDependentOn
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

validate

IGPMessages validate(boolean updateValues,
                     IGPEnvironmentManager pEnvMgr)
                     throws IOException,
                            AutomationException
Validates the model element.

Product Availability

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

Supported Platforms

Windows

Parameters:
updateValues - The updateValues (in)
pEnvMgr - A reference to a com.esri.arcgis.geoprocessing.IGPEnvironmentManager (in)
Returns:
A reference to a com.esri.arcgis.geodatabase.IGPMessages
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getMessages

IGPMessages getMessages()
                        throws IOException,
                               AutomationException
Returns the messages returned from the last call to Validate().

Product Availability

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

Supported Platforms

Windows

Returns:
A reference to a com.esri.arcgis.geodatabase.IGPMessages
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isAltered

boolean isAltered()
                  throws IOException,
                         AutomationException
Indicates if the model element has been altered by the user.

Product Availability

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

Supported Platforms

Windows

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

setAltered

void setAltered(boolean altered)
                throws IOException,
                       AutomationException
Indicates if the model element has been altered by the user.

Product Availability

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

Supported Platforms

Windows

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