com.esri.arcgis.controls
Interface IEngineEditLayers

All Superinterfaces:
Serializable
All Known Implementing Classes:
EngineEditor

public interface IEngineEditLayers
extends Serializable

Provides access to members that control information about layers in the edit session.

Description

This interface is new at ArcGIS 9.3.

The IEngineEditLayers interface is used to access information about layers involved in an edit session. For example, use IEngineEditLayers to determine if a particular layer involved in an edit session is editable or not; in addition,
use IEngineEditLayers to check or set the editorís current layer and current subtype.

The target layer determines which layer will receive newly created features. Edit tasks and commands that create new features use this property to determine to which layer to write out the new features.

Product Availability

Available with ArcGIS Engine.


Method Summary
 int getCurrentSubtype()
          The sub type for new features in the CurrentLayer.
 IFeatureLayer IEngineEditLayers_getTargetLayer()
          The EngineEditor's target layer that new features are added to.
 boolean isEditable(IFeatureLayer layer)
          Indicates if the specific feature layer is editable.
 void setTargetLayer(IFeatureLayer layer, int subType)
          Sets the EngineEditor's target layer and subtype for new features.
 

Method Detail

setTargetLayer

void setTargetLayer(IFeatureLayer layer,
                    int subType)
                    throws IOException,
                           AutomationException
Sets the EngineEditor's target layer and subtype for new features.

Description

Use this method to set the EngineEditor's target layer. The target layer is the layer that new features are typically written to by commands or edit tasks. For example, the "Create New Feature" task creates new features and stores them in the target layer.

If the ControlsEditingTargetToolControl is present it automatically sets the target layer to be the first editable layer in the map when editing starts and it's layer list will be updated when this method is called.

This method should only be called for those layers where IEngineEditLayers::IsEditable returns a True value. To programmatically edit features in an editable layer you do not have to call the SetTargetLayer method.

Remarks

This method fires IEngineEditEvents::OnTargetLayerChanged and IEngineEditEvents::OnSketchModified.

Product Availability

Available with ArcGIS Engine.

Parameters:
layer - A reference to a com.esri.arcgis.carto.IFeatureLayer (in)
subType - The subType (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

IEngineEditLayers_getTargetLayer

IFeatureLayer IEngineEditLayers_getTargetLayer()
                                               throws IOException,
                                                      AutomationException
The EngineEditor's target layer that new features are added to.

Product Availability

Available with ArcGIS Engine.

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

getCurrentSubtype

int getCurrentSubtype()
                      throws IOException,
                             AutomationException
The sub type for new features in the CurrentLayer.

Description

Returns the subtype code for the target layer. If the IEngineEditLayers::TargetLayer does not have any subtypes then 0 is returned.

Product Availability

Available with ArcGIS Engine.

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

isEditable

boolean isEditable(IFeatureLayer layer)
                   throws IOException,
                          AutomationException
Indicates if the specific feature layer is editable.

Description

Use the IsEditable method to check if a particular layer is editable.

When an edit session is started this method is automatically called for each layer in the Map. Only editable layers are added to the ControlsEditingTargetToolControl.

Product Availability

Available with ArcGIS Engine.

Parameters:
layer - A reference to a com.esri.arcgis.carto.IFeatureLayer (in)
Returns:
The pEditable
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.