|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IOperationStack
Provides access to members that control the Operation Stack.
An application can implement an OperationStack to provide undo and redo facilities. As you carry out operations, they are added to the stack, then you can use undo and redo in the application to manipulate the stack to undo or redo the operations.
ArcMap has an OperationStack, which can be obtained with the IMxDocument::OperationStack property. ArcMap’s buttons and tools wrap their actions in an operation and add the operations to the stack.
Depending on your scenario, there are different methodologies for creating an operation and adding it to the OperationStack.
Method Summary | |
---|---|
void |
esri_do(IOperation operation)
Performs the given operation and places it on the stack. |
int |
getCount()
The number of operations on the stack. |
IOperation |
getItem(int index)
The operation at the specified index. |
IOperation |
getRedoOperation()
Redoes a specified operation. |
IOperation |
getUndoOperation()
Undoes a specified operation. |
void |
redo()
Redoes the next operation on the stack. |
void |
remove(int index)
Removes an operation from the stack. |
void |
reset()
Removes all operations from the stack. |
void |
undo()
Undoes the previous operation on the stack. |
Method Detail |
---|
int getCount() throws IOException, AutomationException
Returns the number of operations on the OperationStack.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.IOperation getItem(int index) throws IOException, AutomationException
index
- The index (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void reset() throws IOException, AutomationException
This method removes all operations from the OperationStack.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void esri_do(IOperation operation) throws IOException, AutomationException
operation
- A reference to a com.esri.arcgis.systemUI.IOperation (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void undo() throws IOException, AutomationException
The Undo method performs the undo of the 'current' operation on the OperationStack and moves the 'current' operation pointer back one operation on the OperationStack.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void redo() throws IOException, AutomationException
The Redo method performs the redo of the 'next' operation on the OperationStack and moves the 'current' operation pointer forward one operation on the OperationStack.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.IOperation getUndoOperation() throws IOException, AutomationException
Returns the 'current' operation on the OperationStack, without executing an undo.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.IOperation getRedoOperation() throws IOException, AutomationException
Returns the 'next' operation on the OperationStack, without executing an redo.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void remove(int index) throws IOException, AutomationException
Removes the operation at the specified index from the OperationStack. The operation at the beginning of the collection has an index of 0 and the operation at the end of the collection has an index of IOperationStack::Count - 1.
index
- The index (in)
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 |