|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.esri.arcgis.controls.EngineEditor
public class EngineEditor
A singleton object representing the Engine editing environment.
The EngineEditor is a singleton object (only one instance of the EngineEditor object is supported per thread) that manages the editing environment for features stored in the ESRI vector geographic datasets: geodatabases and shapefiles. Use the EngineEditor object to control the editing properties, establish a snapping environment, manage snap agents, create edit operations, create and manage an edit sketch, set the current task, set the target layer and to respond to editor events.
Field Summary |
---|
Fields inherited from interface com.esri.arcgis.system.IExtension |
---|
IID, IID7f657ec9_dbf1_11d2_9f2f_00c04f6bc69e, xxDummy |
Constructor Summary | |
---|---|
EngineEditor()
Constructs a EngineEditor using ArcGIS Engine. |
|
EngineEditor(Object obj)
Deprecated. As of ArcGIS 9.2, replaced by normal Java casts. EngineEditor theEngineEditor = (EngineEditor) obj; |
Method Summary | |
---|---|
void |
abortOperation()
Aborts an edit operation. |
void |
addIEngineEditEventsListener(IEngineEditEvents theListener)
addIEngineEditEventsListener. |
void |
addPoint(IPoint point,
boolean allowUndo)
Adds a point to the edit sketch. |
void |
addSnapAgent(IEngineSnapAgent snapAgent)
Adds a new snap agent to the snap environment. |
void |
addTask(IEngineEditTask task)
Adds a task to the EngineEditor. |
void |
clearSnapAgents()
Removes all snap agents. |
void |
enableUndoRedo(boolean enabled)
Indicates if undo/redo capabilities are enabled. |
boolean |
equals(Object o)
Compare this object with another |
void |
finishSketch()
Completes the current edit sketch. |
void |
finishSketchPart()
Completes a part for the current edit sketch. |
double |
getAngularCorrectionOffset()
Angular Correction Offset. |
int |
getAngularUnitPrecision()
Precision used to display angular units. |
static String |
getClsid()
getClsid. |
int |
getCurrentSubtype()
The sub type for new features in the CurrentLayer. |
IEngineEditTask |
getCurrentTask()
The current edit task. |
double |
getCurrentZ()
Current Z value for the edit sketch. |
int |
getDirectionType()
Direction Type. |
int |
getDirectionUnits()
Direction Units. |
double |
getDistanceCorrectionFactor()
Distance Correction Factor. |
IPoint |
getEditLocation()
A point that can be used by any custom editing commands. |
IEnumFeature |
getEditSelection()
The selected features that are editable. |
int |
getEditSessionMode()
The current edit session mode. |
int |
getEditState()
The EngineEditor's current edit state. |
IWorkspace |
getEditWorkspace()
The workspace being edited. |
IGeometry |
getGeometry()
Geometry stored in the edit sketch. |
int |
getGeometryType()
Type of the geometry stored in the edit sketch. |
IPoint |
getLastPoint()
The last point in the edit sketch. |
IMap |
getMap()
The map being edited. |
String |
getName()
The name of the extension. |
int |
getPart()
The index of the current part of the sketch. |
int |
getReportPrecision()
Controls the number of decimal places the editor reports numbers with. |
int |
getSegment()
The index of the current segment of the sketch. |
IMarkerSymbol |
getSelectedVertexSymbol()
Symbol used to draw the active vertex of the edit sketch. |
IAnchorPoint |
getSelectionAnchor()
The selection anchor point. |
int |
getSelectionCount()
The number of selected features that are editable. |
ILineSymbol |
getSketchSymbol()
Symbol used to draw the lines of the edit sketch. |
IMarkerSymbol |
getSketchVertexSymbol()
Symbol used to draw the vertices of the edit sketch. |
IEngineSnapAgent |
getSnapAgent(int index)
A snap agent at the given index. |
int |
getSnapAgentCount()
The number of active snap agents. |
IMarkerSymbol |
getSnapSymbol()
Symbol used to draw the snap location. |
double |
getSnapTolerance()
The snap tolerance, measured in pixels or map units. |
int |
getSnapToleranceUnits()
The units used for the snap tolerance. |
int |
getStickyMoveTolerance()
Controls the sticky move tolerance. |
int |
getStreamGroupingCount()
Controls the number of points to group together when streaming. |
double |
getStreamTolerance()
Controls the streaming tolerance, measured in map units. |
ILayer |
getTargetLayer()
The editor's target layer. |
IEngineEditTask |
getTask(int index)
The edit task at the specified index. |
IEngineEditTask |
getTaskByUniqueName(String uniqueName)
Retrieves a task by UniqueName from the EngineEditor. |
int |
getTaskCount()
The number of edit tasks. |
int |
getVertex()
The index of the current vertex of the sketch. |
boolean |
hasEdits()
Indicates if edits have been made. |
int |
hashCode()
the hashcode for this object |
IFeatureLayer |
IEngineEditLayers_getTargetLayer()
The EngineEditor's target layer that new features are added to. |
void |
interfaceSupportsErrorInfo(GUID riid)
interfaceSupportsErrorInfo |
void |
invertAgent(IPoint location,
int hdc)
Draws the EngineEditor's snapping agent. |
boolean |
isAutoSaveOnVersionRedefined()
Indicates whether the stop editing process should automatically reconcile an edit session and save the version without notification. |
boolean |
isEditable(IFeatureLayer layer)
Indicates if the specific feature layer is editable. |
boolean |
isSnapTips()
Indicates whether to show the snap tips. |
boolean |
isStretchGeometry()
Indicates if the edit sketch is stretched when one of its vertices is moved. |
boolean |
isUseGroundToGrid()
Indicates whether to use Ground to Grid. |
boolean |
isZAware()
Indicates whether the edit sketch geometry can contain Zs. |
void |
modifySketch()
Notifies listeners that the sketch has been changed. |
void |
refreshSketch()
Invalidates the portion of the display that is occupied by the sketch. |
void |
removeIEngineEditEventsListener(IEngineEditEvents theListener)
removeIEngineEditEventsListener. |
void |
removeSnapAgent(int index)
Removes the snap agent at the given index. |
void |
setAngularCorrectionOffset(double angOffset)
Angular Correction Offset. |
void |
setAngularUnitPrecision(int auPrecision)
Precision used to display angular units. |
void |
setAutoSaveOnVersionRedefined(boolean stretch)
Indicates whether the stop editing process should automatically reconcile an edit session and save the version without notification. |
void |
setCurrentTaskByRef(IEngineEditTask task)
The current edit task. |
void |
setCurrentZ(double z)
Current Z value for the edit sketch. |
void |
setDirectionType(int dirType)
Direction Type. |
void |
setDirectionUnits(int dirUnits)
Direction Units. |
void |
setDistanceCorrectionFactor(double distFactor)
Distance Correction Factor. |
void |
setEditLocation(int x,
int y)
Sets the part, segment and vertex of the edit sketch at the x,y location. |
void |
setEditSessionMode(int mode)
The current edit session mode. |
void |
setGeometryByRef(IGeometry geometry)
Geometry stored in the edit sketch. |
void |
setGeometryType(int geomType)
Type of the geometry stored in the edit sketch. |
void |
setReportPrecision(int numDecs)
Controls the number of decimal places the editor reports numbers with. |
void |
setSelectedVertexSymbolByRef(IMarkerSymbol symbol)
Symbol used to draw the active vertex of the edit sketch. |
void |
setSketchSymbolByRef(ILineSymbol symbol)
Symbol used to draw the lines of the edit sketch. |
void |
setSketchVertexSymbolByRef(IMarkerSymbol symbol)
Symbol used to draw the vertices of the edit sketch. |
void |
setSnapSymbolByRef(IMarkerSymbol symbol)
Symbol used to draw the snap location. |
void |
setSnapTips(boolean tips)
Indicates whether to show the snap tips. |
void |
setSnapTolerance(double tol)
The snap tolerance, measured in pixels or map units. |
void |
setSnapToleranceUnits(int units)
The units used for the snap tolerance. |
void |
setStickyMoveTolerance(int tol)
Controls the sticky move tolerance. |
void |
setStreamGroupingCount(int tol)
Controls the number of points to group together when streaming. |
void |
setStreamTolerance(double tol)
Controls the streaming tolerance, measured in map units. |
void |
setStretchGeometry(boolean stretch)
Indicates if the edit sketch is stretched when one of its vertices is moved. |
void |
setTargetLayer(IFeatureLayer layer,
int subType)
Sets the EngineEditor's target layer and subtype for new features. |
void |
setUseGroundToGrid(boolean g2g)
Indicates whether to use Ground to Grid. |
void |
setZAware(boolean aware)
Indicates whether the edit sketch geometry can contain Zs. |
void |
shutdown()
Shuts down the extension. |
boolean |
snapPoint(IPoint point)
Attempts to snap the point using the current snap environment. |
void |
startEditing(IWorkspace workspace,
IMap map)
Starts an edit session. |
void |
startOperation()
Starts an edit operation. |
void |
startup(Object initializationData)
Starts up the extension with the given initialization data. |
void |
stopEditing(boolean saveChanges)
Stops an edit session. |
void |
stopOperation(String operationName)
Stops an edit operation. |
void |
vertexAdded(IPoint point)
Notifies listeners that a vertex has been added to the sketch. |
void |
vertexDeleted(IPoint point)
Notifies listeners that a vertex has been deleted from the sketch. |
void |
vertexMoved(IPoint point)
Notifies listeners that a vertex has been moved in the sketch. |
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 EngineEditor() throws IOException, UnknownHostException
IOException
- if there are interop problems
UnknownHostException
- if there are interop problemspublic EngineEditor(Object obj) throws IOException
EngineEditor theEngineEditor = (EngineEditor) obj;
obj
to EngineEditor
.
obj
- an object returned from ArcGIS Engine or Server
IOException
- if there are interop problemsMethod Detail |
---|
public static String getClsid()
public boolean equals(Object o)
equals
in class Object
public int hashCode()
hashCode
in class Object
public void addIEngineEditEventsListener(IEngineEditEvents theListener) throws IOException
theListener
- An object that implements the com.esri.arcgis.controls.IEngineEditEvents interface.
IOException
- If there are communications problems.public void removeIEngineEditEventsListener(IEngineEditEvents theListener) throws IOException
theListener
- An object that implements the com.esri.arcgis.controls.IEngineEditEvents interface.
IOException
- If there are communications problems.public int getEditState() throws IOException, AutomationException
The EditState property communicates the current edit state of the EngineEditor. The esriEngineEditState constants provide the valid edit states.
getEditState
in interface IEngineEditor
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public IWorkspace getEditWorkspace() throws IOException, AutomationException
The EditWorkspace property returns a reference to the workspace being edited. Only one workspace can be edited at a time. The EditWorkspace property is set by the IEngineEditor::StartEditing method and the ControlsEditingStartCommand.
getEditWorkspace
in interface IEngineEditor
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void startEditing(IWorkspace workspace, IMap map) throws IOException, AutomationException
Starts an editing session using the specified IMap and IWorkspace parameters. Only one map and workspace can be edited at a time.
This method fires the IEngineEditEvents::OnStartEditing, IEngineEditEvents::OnSelectionChanged, IEngineEditEvents::OnTargetLayerChanged and IEngineEditEvents::OnSketchModified events.
startEditing
in interface IEngineEditor
workspace
- A reference to a com.esri.arcgis.geodatabase.IWorkspace (in)map
- A reference to a com.esri.arcgis.carto.IMap (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void stopEditing(boolean saveChanges) throws IOException, AutomationException
Stops an editing session. Changes can be saved by setting the saveChanges parameter to be True or discarded by setting the parameter to be False.
StopEditing also clears all snap agents and unselects all selected features.
This method fires the IEngineEditEvents::OnBeforeStopEditing, IEngineEditEvents::OnStopEditing and IEngineEditEvents::OnTargetLayerChanged events.
stopEditing
in interface IEngineEditor
saveChanges
- The saveChanges (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public boolean hasEdits() throws IOException, AutomationException
This property reports whether or not any edits have been made in the current edit session. For example, if this property returns False then editing can be stopped without saving the changes by calling IEngineEditor::StopEditing with the False parameter.
hasEdits
in interface IEngineEditor
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void startOperation() throws IOException, AutomationException
StartOperation marks the beginning of an edit operation. To provide undo/redo capability programmatically all edits must be performed within an edit operation.
Calling IEngineEditor::StopOperation completes an edit operation which is then added to the top of the operation stack. The operation stack is how ArcGIS Engine implements Undo and Redo. When using StartOperation, proper error handling, including the use of IEgineEditor::AbortOperation, is neccessary.
Edit operations cannot be nested; calling StartOperation within another operation will raise an error.
This method fires the IEngineEditEvents::OnStartOperation event.
startOperation
in interface IEngineEditor
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void abortOperation() throws IOException, AutomationException
AbortOperation should be used to terminate the edit operation without saving any changes. Those changes that were made after IEngineEditor::StartOperation was called are undone, and nothing is added to the operation stack.
You may wish to test that your edit operation is valid before saving any changes. If the test fails you should call AbortOperation instead of IEngineEditor::StopOperation.
This method fires theIEngineEditEvents::OnSelectionChanged and IEngineEditEvents::OnAbort events.
abortOperation
in interface IEngineEditor
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void stopOperation(String operationName) throws IOException, AutomationException
StopOperation marks the end of an edit operation. Calling StopOperation creates an edit operation that is added to the top of the operation stack. The operation stack is how ArcGIS Engine implements Undo and Redo.
When using IEngineEditor::StartOperation proper handling of errors, including the use of IEngineEditor::AbortOperation, is neccessary.
The string argument allows the operation to be identified on the operaton stack.
This method fires the IEngineEditEvents::OnBeforeStopOperation and IEngineEditEvents::OnStopOperation events.
stopOperation
in interface IEngineEditor
operationName
- The operationName (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void enableUndoRedo(boolean enabled) throws IOException, AutomationException
Use EnableUndoRedo to control whether edits to features can be rolled back. When set to True, an edit made programmatically must be performed within an edit operation so that it can be rolled back. When set to False, no individual edit operation can be undone.
Calling IEngineEditor::StopEditing with a False parameter will discard all of the edits made in the edit session.
By default EnableUndoRedo is True. The method can only be called when there is an active edit session and only applies to edit operations; it does not apply to sketch operations.
enableUndoRedo
in interface IEngineEditor
enabled
- The enabled (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public IEnumFeature getEditSelection() throws IOException, AutomationException
This property returns all of the currently selected features that belong to editable layers. Use this property when creating an editing tool or command that works with the current selection.
getEditSelection
in interface IEngineEditor
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public int getSelectionCount() throws IOException, AutomationException
This property returns total number of selected features belonging to all editable layers in a map.
getSelectionCount
in interface IEngineEditor
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public int getTaskCount() throws IOException, AutomationException
This property returns the number of engine edit tasks that the EngineEditor currently has loaded.
For example, use TaskCount to loop through all available tasks.
getTaskCount
in interface IEngineEditor
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public IEngineEditTask getTask(int index) throws IOException, AutomationException
getTask
in interface IEngineEditor
index
- The index (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setCurrentTaskByRef(IEngineEditTask task) throws IOException, AutomationException
setCurrentTaskByRef
in interface IEngineEditor
task
- A reference to a com.esri.arcgis.controls.IEngineEditTask (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public IEngineEditTask getCurrentTask() throws IOException, AutomationException
Use this property to check or change the EngineEditor's current task.
When an edit sketch is completed the IEngineEditTask::OnFinishSketch method of the current engine edit task uses the geometry stored in IEngineEditSketch::Geometry to perform some action (e.g. store any created features)
The IEngineEditEvents::OnCurrentTaskChanged event is fired when this property is set or when a different task is selected using the ControlsEditingTaskToolControl.
getCurrentTask
in interface IEngineEditor
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public IMap getMap() throws IOException, AutomationException
Use this property to get a reference to the map being edited.
An application may contain more than one MapControl encapsulating a Map CoClass. Only the editable layers in one Map may be edited at a time. When IEngineEditor::StartEditing is called, an edit session begins on a specific workspace in a specific map.
getMap
in interface IEngineEditor
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void invertAgent(IPoint location, int hdc) throws IOException, AutomationException
Call InvertAgent to draw the EngineEditor's snap agent at the location specified by the required point parameter. A device handle is also required. The agent is typically used to display the mouse location or a location based on a constraint when adding points to an edit sketch. Call InvertAgent a second time with the same point parameter to draw over and erase the previous agent.
invertAgent
in interface IEngineEditor
location
- A reference to a com.esri.arcgis.geometry.IPoint (in)hdc
- The hdc (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void addTask(IEngineEditTask task) throws IOException, AutomationException
This method adds an engine edit task to the collection of edit tasks managed by the EngineEditor singleton object.
addTask
in interface IEngineEditor
task
- A reference to a com.esri.arcgis.controls.IEngineEditTask (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public IEngineEditTask getTaskByUniqueName(String uniqueName) throws IOException, AutomationException
Retrieves the engine edit task that is uniquely identified by it's IEngineEditTask::UniqueName string.
For example, the out-of-the-box "Create New Feature" and "Modify Feature" engine edit tasks have IEngineEditTask::UniqueName properties of "ControlToolsEditing_CreateNewFeatureTask" and "ControlToolsEditing_ModifyFeatureTask" respectively.
getTaskByUniqueName
in interface IEngineEditor
uniqueName
- The uniqueName (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setEditSessionMode(int mode) throws IOException, AutomationException
setEditSessionMode
in interface IEngineEditor
mode
- A com.esri.arcgis.controls.esriEngineEditSessionMode constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public int getEditSessionMode() throws IOException, AutomationException
Use this property to check or set the edit session mode of the EngineEditor. The edit session can be either versioned or non-versioned. This property only applies when editing an SDE Workspace.
The esriEngineEditSessionMode constants provide the valid edit session modes.
getEditSessionMode
in interface IEngineEditor
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public IAnchorPoint getSelectionAnchor() throws IOException, AutomationException
Editing tools that require the location of the selection anchor can conveniently get it from the SelectionAnchor property. For example, the editor's Rotate Tool rotates features around the selection anchor.
getSelectionAnchor
in interface IEngineEditor2
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public int getGeometryType() throws IOException, AutomationException
Use this property in conjunction with the IEngineEditSketch::Geometry property to manage the geometry inside the edit sketch. Setting GeometryType automatically initializes the IEngineEditSketch::Geometry property and vice versa. For example, if you set the GeometryType to esriGeometryPolygon, a new empty Polygon object will be created.
Valid esriGeometryType constants used by IEngineEditSketch are: esriGeometryPoint, esriGeometryMultipoint, esriGeometryPolyline, esriGeometryPolygon and esriGeometryNull.
getGeometryType
in interface IEngineEditSketch
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setGeometryType(int geomType) throws IOException, AutomationException
setGeometryType
in interface IEngineEditSketch
geomType
- A com.esri.arcgis.geometry.esriGeometryType constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public IGeometry getGeometry() throws IOException, AutomationException
This property sets the geometry that the EngineEditor works with and ultimately passes it to the current task. By default, the EngineEditor creates a new empty geometry any time an edit session is started, the target layer is changed, the GeometryType is reset, or a task is completed. There is generally no need, therefore, to set the Geometry property when you are building new geometries.
Do set the Geometry property, however, when you want to bring an existing feature into the edit sketch.
Valid esriGeometryType constants used by IEngineEditSketch are: esriGeometryPoint, esriGeometryMultipoint, esriGeometryPolyline, esriGeometryPolygon and esriGeometryNull.
getGeometry
in interface IEngineEditSketch
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setGeometryByRef(IGeometry geometry) throws IOException, AutomationException
setGeometryByRef
in interface IEngineEditSketch
geometry
- A reference to a com.esri.arcgis.geometry.IGeometry (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public IPoint getEditLocation() throws IOException, AutomationException
getEditLocation
in interface IEngineEditSketch
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public int getPart() throws IOException, AutomationException
getPart
in interface IEngineEditSketch
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public int getSegment() throws IOException, AutomationException
getSegment
in interface IEngineEditSketch
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public int getVertex() throws IOException, AutomationException
getVertex
in interface IEngineEditSketch
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void addPoint(IPoint point, boolean allowUndo) throws IOException, AutomationException
Use the AddPoint method to add a point to the geometry held in the edit sketch. The point parameter specifies the next point in the sketch. In all cases, new segments are added linking the edit sketch to the provided point, except where the geometry type is set to Point or the point represents the very first point in the edit sketch.
This method fires the IEngineEditEvents::OnVertexAdded, IEngineEditEvents::OnSketchModified and IEngineEditEvents::OnAfterDrawSketch events.
addPoint
in interface IEngineEditSketch
point
- A reference to a com.esri.arcgis.geometry.IPoint (in)allowUndo
- The allowUndo (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void refreshSketch() throws IOException, AutomationException
Call RefreshSketch to invalidate the portion of the display that is occupied by the sketch. Sometimes, however, it may be necessary to invalidate a larger portion of the display in order to get rid of unwanted artifacts. This situation can arise when you shorten the length of a segment since old data may still be erroneously displayed outside of the new sketch geometry.
This method fires the IEngineEditEvents::OnAfterDrawSketch event.
refreshSketch
in interface IEngineEditSketch
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void finishSketch() throws IOException, AutomationException
The FinishSketch method finishes the edit sketch and notifies the EngineEditor's current task of this event which executes the IEngineEditTask::OnFinishSketch method. For example, the "Create New Feature" edit task will create a new feature using the IEngineEditSketch::Geometry. A number of events may be fired by the IEngineEditTask::OnFinishSketch method depending on the task being executed.
finishSketch
in interface IEngineEditSketch
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void finishSketchPart() throws IOException, AutomationException
The FinishSketchPart method finishes the edit sketch part during the creation of multi-part geometries.
This method fires the IEngineEditEvents::OnAfterDrawSketch event.
finishSketchPart
in interface IEngineEditSketch
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public IPoint getLastPoint() throws IOException, AutomationException
Use this property to retrieve the last point in the edit sketch.
getLastPoint
in interface IEngineEditSketch
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void modifySketch() throws IOException, AutomationException
Call ModifySketch if you are programmatically modifying an edit sketch. The ModifySketch method will programmatically fire the IEngineEditEvents::OnSketchModified event, thus ensuring that all listening clients are notified.
modifySketch
in interface IEngineEditSketch
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void vertexAdded(IPoint point) throws IOException, AutomationException
Call VertexAdded if you are programmatically adding a vertex to an edit sketch. The VertexAdded method will programmatically fire the IEngineEditEvents::OnVertexAdded event, thus ensuring that all listening clients are notified.
vertexAdded
in interface IEngineEditSketch
point
- A reference to a com.esri.arcgis.geometry.IPoint (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void vertexDeleted(IPoint point) throws IOException, AutomationException
Call VertexDeleted if you are programmatically deleting a vertex from an edit sketch. The VertexDeleted method will programmatically fire the IEngineEditEvents::OnVertexDeleted event, thus ensuring that all listening clients are notified.
vertexDeleted
in interface IEngineEditSketch
point
- A reference to a com.esri.arcgis.geometry.IPoint (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void vertexMoved(IPoint point) throws IOException, AutomationException
Call VertexMoved if you are programmatically moving a vertex in an edit sketch. The VertexMoved method will programmatically fire the IEngineEditEvents::OnVertexMoved event, thus ensuring that all listening clients are notified.
vertexMoved
in interface IEngineEditSketch
point
- A reference to a com.esri.arcgis.geometry.IPoint (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setEditLocation(int x, int y) throws IOException, AutomationException
Call the SetEditLocation method to store the EditLocation, Vertex, Segment and/or Part of an edit sketch.
It is essential that this method is called prior to executing any of the following commands; ControlsEditingVertexInsertCommand, ControlsEditingVertexDeleteCommand, ControlsEditingVertexMoveCommand and ControlsEditingVertexMoveToCommand or popping up the ControlsEditingVertexContextMenu.
setEditLocation
in interface IEngineEditSketch
x
- The x (in)y
- The y (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public boolean isZAware() throws IOException, AutomationException
If the IEngineEditSketch::Geometry contains elevation (z) values, this property will return a boolean value of True.
To view the z values for the edit sketch display the edit sketch properties dialog using the ControlsEditingSketchPropertiesCommand and select the sketch. If the sketch is ZAware, an additional column will appear next to the y column showing the z values.
isZAware
in interface IEngineEditSketch
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setZAware(boolean aware) throws IOException, AutomationException
setZAware
in interface IEngineEditSketch
aware
- The aware (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public double getCurrentZ() throws IOException, AutomationException
To view the z values for the edit sketch display the edit sketch properties dialog using the ControlsEditingSketchPropertiesCommand and select the sketch. If the sketch is ZAware, an additional column will appear next to the y column showing the z values.
getCurrentZ
in interface IEngineEditSketch
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setCurrentZ(double z) throws IOException, AutomationException
setCurrentZ
in interface IEngineEditSketch
z
- The z (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public boolean snapPoint(IPoint point) throws IOException, AutomationException
SnapPoint passes the required point parameter to each of the added snap agents in the order that these agents were added. The agents attempt, in turn, to find point coordinates that fulfill its snap properties for the incoming point. If a new snap location is found, the relevant snap agent modifies the original point's coordinates to that of the new location. The same point is then returned to SnapPoint. Once a snap agent is found that satisfies the point subsequent snap agents are not tested.
As an example: there may be several feature snap agents present. Each receives a point from the current cursor location, which is passed to the agent via the SnapPoint method. If the conditions for a snap are met, the boolean value of the agent returns TRUE, the point's coordinates are updated based on the active feature snap conditions and the same point is returned to SnapPoint.
snapPoint
in interface IEngineSnapEnvironment
point
- A reference to a com.esri.arcgis.geometry.IPoint (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public int getSnapToleranceUnits() throws IOException, AutomationException
SnapToleranceUnits defines the units used to define the radius used by active snap agents. By default The default SnapToleranceUnits is esriSnapTolerancePixels.
getSnapToleranceUnits
in interface IEngineSnapEnvironment
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setSnapToleranceUnits(int units) throws IOException, AutomationException
setSnapToleranceUnits
in interface IEngineSnapEnvironment
units
- A com.esri.arcgis.controls.esriEngineSnapToleranceUnits constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public double getSnapTolerance() throws IOException, AutomationException
getSnapTolerance
in interface IEngineSnapEnvironment
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setSnapTolerance(double tol) throws IOException, AutomationException
setSnapTolerance
in interface IEngineSnapEnvironment
tol
- The tol (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public int getSnapAgentCount() throws IOException, AutomationException
SnapAgentCount returns the number of currently active snap agents.
getSnapAgentCount
in interface IEngineSnapEnvironment
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public IEngineSnapAgent getSnapAgent(int index) throws IOException, AutomationException
getSnapAgent
in interface IEngineSnapEnvironment
index
- The index (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void clearSnapAgents() throws IOException, AutomationException
clearSnapAgents
in interface IEngineSnapEnvironment
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void removeSnapAgent(int index) throws IOException, AutomationException
removeSnapAgent
in interface IEngineSnapEnvironment
index
- The index (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void addSnapAgent(IEngineSnapAgent snapAgent) throws IOException, AutomationException
AddSnapAgent activates and adds to the snap environment any valid snap agent. Snap agents which have already been added are not changed by this method. Snap agents are identified by their SnapAgent.Name and GUID.
addSnapAgent
in interface IEngineSnapEnvironment
snapAgent
- A reference to a com.esri.arcgis.controls.IEngineSnapAgent (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public int getReportPrecision() throws IOException, AutomationException
Use ReportPrecision to control the number of decimal places reported back from editing functions. By default ReportPrecision is set to 3.
getReportPrecision
in interface IEngineEditProperties
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setReportPrecision(int numDecs) throws IOException, AutomationException
setReportPrecision
in interface IEngineEditProperties
numDecs
- The numDecs (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public double getStreamTolerance() throws IOException, AutomationException
Use StreamTolerance to set the number of points that get added to a map (in map units) by the ControlsEditingSketchTool when in stream mode. By default StreamTolerance is 0.
Use the ControlsEditingSketchStreamingCommand to set the ControlsEditingSketchTool in stream mode.
getStreamTolerance
in interface IEngineEditProperties
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setStreamTolerance(double tol) throws IOException, AutomationException
setStreamTolerance
in interface IEngineEditProperties
tol
- The tol (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public int getStreamGroupingCount() throws IOException, AutomationException
The StreamGroupingCount property controls how many grouped points are added to the undo stack by the ControlsEditingSketchTool when in stream mode. By default StreamGroupingCount is 50.
If StreamGroupingCount is 1 each streamed point added will be undoable and redoable. If the streaming tolerance is low, however, you may wish to make the grouping larger so that groups of added points can be undone or redone by the user with only one undo or redo.
Use the ControlsEditingSketchStreamingCommand to set the ControlsEditingSketchTool in stream mode.
getStreamGroupingCount
in interface IEngineEditProperties
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setStreamGroupingCount(int tol) throws IOException, AutomationException
setStreamGroupingCount
in interface IEngineEditProperties
tol
- The tol (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public boolean isStretchGeometry() throws IOException, AutomationException
StretchGeometry determines whether or not the edit sketch is stretched proportionally when a vertex is moved. By default StretchGeometryis false.
The following diagrams illustrate this point better. In both cases, the upper right vertex was moved.
Moving a vertex with StretchGeometry set to True:
Moving a vertex with StretchGeometry set to False:
isStretchGeometry
in interface IEngineEditProperties
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setStretchGeometry(boolean stretch) throws IOException, AutomationException
setStretchGeometry
in interface IEngineEditProperties
stretch
- The stretch (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public ILineSymbol getSketchSymbol() throws IOException, AutomationException
getSketchSymbol
in interface IEngineEditProperties
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setSketchSymbolByRef(ILineSymbol symbol) throws IOException, AutomationException
setSketchSymbolByRef
in interface IEngineEditProperties
symbol
- A reference to a com.esri.arcgis.display.ILineSymbol (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public IMarkerSymbol getSketchVertexSymbol() throws IOException, AutomationException
getSketchVertexSymbol
in interface IEngineEditProperties
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setSketchVertexSymbolByRef(IMarkerSymbol symbol) throws IOException, AutomationException
setSketchVertexSymbolByRef
in interface IEngineEditProperties
symbol
- A reference to a com.esri.arcgis.display.IMarkerSymbol (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public IMarkerSymbol getSelectedVertexSymbol() throws IOException, AutomationException
getSelectedVertexSymbol
in interface IEngineEditProperties
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setSelectedVertexSymbolByRef(IMarkerSymbol symbol) throws IOException, AutomationException
setSelectedVertexSymbolByRef
in interface IEngineEditProperties
symbol
- A reference to a com.esri.arcgis.display.IMarkerSymbol (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public IMarkerSymbol getSnapSymbol() throws IOException, AutomationException
getSnapSymbol
in interface IEngineEditProperties
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setSnapSymbolByRef(IMarkerSymbol symbol) throws IOException, AutomationException
setSnapSymbolByRef
in interface IEngineEditProperties
symbol
- A reference to a com.esri.arcgis.display.IMarkerSymbol (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public boolean isAutoSaveOnVersionRedefined() throws IOException, AutomationException
Auto reconciliation provides the user the ability to delay the save process for after the reconciliation. This allows the user to inspect the results of the reconciliation prior to saving. By default AutoSaveOnVersionRedefined is false.
If AutoSaveOnVersionRedefined is true, auto reconciliation will automatically reconcile the edit session with the version's current database state and save, making changes available to others using the database.
If AutoSaveOnVersionRedefined is false, when a save occurs, the edit session will be reconciled with the version's current database state, and then a message will inform the user that the edit session has been reconciled but has not been saved.
isAutoSaveOnVersionRedefined
in interface IEngineEditProperties
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setAutoSaveOnVersionRedefined(boolean stretch) throws IOException, AutomationException
setAutoSaveOnVersionRedefined
in interface IEngineEditProperties
stretch
- The stretch (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public ILayer getTargetLayer() throws IOException, AutomationException
The target layer (or current layer) to be editied. For example, if the target layer is set to 'Buildings' any new features created will be part of the 'Buildings' layer.
The TargetLayer gets set when the end user interactively selects a layer using the ControlsEditingTargetToolControl.
getTargetLayer
in interface IEngineEditProperties
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public int getStickyMoveTolerance() throws IOException, AutomationException
StickyMoveTolerance determines the minimum distance (measured in pixels) the cursor must move before the edit is completed. This can be helpful in preventing small inadvertent shifts of features when editing. By default StickyMoveTolerance is 0.
getStickyMoveTolerance
in interface IEngineEditProperties2
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setStickyMoveTolerance(int tol) throws IOException, AutomationException
setStickyMoveTolerance
in interface IEngineEditProperties2
tol
- The tol (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public boolean isSnapTips() throws IOException, AutomationException
Use SnapTips to determine whether snap tips are displayed when using the snapping envionrment. By default SnapTips is false.
Snap tips provide feedback in the form of a tool tip and a message in the status bar identifying the snap agent that was used to modify the current point. If the snap agent used is a feature snap agent, the layer name and hit type are displayed; otherwise the snap agent name is displayed.
isSnapTips
in interface IEngineEditProperties2
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setSnapTips(boolean tips) throws IOException, AutomationException
setSnapTips
in interface IEngineEditProperties2
tips
- The tips (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setAngularUnitPrecision(int auPrecision) throws IOException, AutomationException
setAngularUnitPrecision
in interface IEngineEditProperties2
auPrecision
- The auPrecision (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public int getAngularUnitPrecision() throws IOException, AutomationException
AngularUnitPrecision determines the number of digits displayed after the decimal place. By default AngularUnitPrecision is 4.
getAngularUnitPrecision
in interface IEngineEditProperties2
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setDirectionType(int dirType) throws IOException, AutomationException
setDirectionType
in interface IEngineEditProperties2
dirType
- A com.esri.arcgis.controls.esriEngineDirectionType constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public int getDirectionType() throws IOException, AutomationException
DirectionType determines the method of measurement for direction values. By default DirectionType is esriDTPolar.
getDirectionType
in interface IEngineEditProperties2
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setDirectionUnits(int dirUnits) throws IOException, AutomationException
setDirectionUnits
in interface IEngineEditProperties2
dirUnits
- A com.esri.arcgis.controls.esriEngineDirectionUnits constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public int getDirectionUnits() throws IOException, AutomationException
DirectionUnits defines how angles are specified; how many parts a complete circle is divided into; and how to interpret the angle value. By default DirectionUnits is esriDUDecimalDegrees.
getDirectionUnits
in interface IEngineEditProperties2
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setDistanceCorrectionFactor(double distFactor) throws IOException, AutomationException
setDistanceCorrectionFactor
in interface IEngineEditProperties2
distFactor
- The distFactor (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public double getDistanceCorrectionFactor() throws IOException, AutomationException
DistanceCorrectionFactor determines the distance amount applied when length measurements are input into the editor. The value may be accessed or modified at any time; however, it is applied only when UseGroundToGrid is set to true. By default DistanceCorrectionFactor is 1.
getDistanceCorrectionFactor
in interface IEngineEditProperties2
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setAngularCorrectionOffset(double angOffset) throws IOException, AutomationException
setAngularCorrectionOffset
in interface IEngineEditProperties2
angOffset
- The angOffset (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public double getAngularCorrectionOffset() throws IOException, AutomationException
AngularCorrectionOffset determines the amount of correction applied to each entered angular value. The offset is specified in radians. This property may be accessed at any time; it is only applied when the UseGroundToGrid is set to true. By default AngularCorrectionOffset is 0 (no correction).
getAngularCorrectionOffset
in interface IEngineEditProperties2
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setUseGroundToGrid(boolean g2g) throws IOException, AutomationException
setUseGroundToGrid
in interface IEngineEditProperties2
g2g
- The g2g (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public boolean isUseGroundToGrid() throws IOException, AutomationException
UseGroundToGrid determines whether any distance or direction offsets are applied to angle or length values respectively when using the editor. By default UseGroundToGrid is false.
If UseGroundToGrid is true then the distance offset specified by DistanceCorrectionFactor and the angular offset specified by AngularCorrectionOffset are used.
isUseGroundToGrid
in interface IEngineEditProperties2
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void setTargetLayer(IFeatureLayer layer, int subType) throws IOException, AutomationException
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.
This method fires IEngineEditEvents::OnTargetLayerChanged and IEngineEditEvents::OnSketchModified.
setTargetLayer
in interface IEngineEditLayers
layer
- A reference to a com.esri.arcgis.carto.IFeatureLayer (in)subType
- The subType (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public IFeatureLayer IEngineEditLayers_getTargetLayer() throws IOException, AutomationException
IEngineEditLayers_getTargetLayer
in interface IEngineEditLayers
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public int getCurrentSubtype() throws IOException, AutomationException
Returns the subtype code for the target layer. If the IEngineEditLayers::TargetLayer does not have any subtypes then 0 is returned.
getCurrentSubtype
in interface IEngineEditLayers
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public boolean isEditable(IFeatureLayer layer) throws IOException, AutomationException
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.
isEditable
in interface IEngineEditLayers
layer
- A reference to a com.esri.arcgis.carto.IFeatureLayer (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void interfaceSupportsErrorInfo(GUID riid) throws IOException, AutomationException
Indicates whether the interface supports IErrorInfo.
interfaceSupportsErrorInfo
in interface ISupportErrorInfo
riid
- A Structure: com.esri.arcgis.support.ms.stdole.GUID (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public String getName() throws IOException, AutomationException
getName
in interface IExtension
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void startup(Object initializationData) throws IOException, AutomationException
startup
in interface IExtension
initializationData
- A Variant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void shutdown() throws IOException, AutomationException
shutdown
in interface IExtension
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 |