GraphUndoUnit Class
This class represents one undoable graph change which appears on the VS undo stack.
Assembly: Microsoft.VisualStudio.GraphModel (in Microsoft.VisualStudio.GraphModel.dll)
| Name | Description | |
|---|---|---|
![]() | GraphUndoUnit(Graph^, GraphUpdatedEventArgs^) | Construct an undo unit from the changes that are about to be committed in the given GraphUpdatedEventArgs. This has to be called during the Graph Updating, the Updated event is too late because we must be able to save the old values before the changes are committed in order to be able to undo those changes. |
| Name | Description | |
|---|---|---|
![]() | Causality | This undo unit's associated Causality. |
![]() | Description | This undo unit's description. |
![]() | Disabled | Whether this undo unit should be disabled (as determined by information found in the constructor). |
![]() | IsEmpty | Whether this undo unit is empty. |
![]() | IsRedoUnit | Whether this is a redo unit. |
![]() | IsUndoUnit | Whether this is an undo unit. |
![]() | ScopeProperties | The property bag associated with this undo unit. |
| Name | Description | |
|---|---|---|
![]() | AddLink(GraphLink^) | Called during Apply if a link has to be added back to the graph. You can override this but you must call base.AddLInk. |
![]() | AddNode(GraphNode^) | Called during Apply if a node has to be added back to the graph. You can override this but you must call base.AddNode. |
![]() | Apply(Action^) | Performs this undo or redo operation. |
![]() | ApplyToGraph(Graph^) | Applies the undo unit to a different graph. |
![]() | ApplyToNode(GraphNode^, GraphNode^) | Applies any property or category changes on the original node to the input node. |
![]() | Equals(Object^) | (Inherited from Object.) |
![]() | Finalize() | (Inherited from Object.) |
![]() | GetHashCode() | (Inherited from Object.) |
![]() | GetType() | (Inherited from Object.) |
![]() ![]() | IsRedo(Dictionary<Object^, Object^>^) | Determines whether the specified GraphTransactionScope is currently being used for a redo operation. |
![]() ![]() | IsUndo(Dictionary<Object^, Object^>^) | Determines whether the specified GraphTransactionScope is currently being used for an undo operation. |
![]() ![]() | IsUndoable(GraphObject^, GraphProperty^) | Return true if changes to the given property on the given graphObject are undoable or not. This method returns true if the property metadata has the IsUndoable flag set or it returns false if it does not have the IsSharable or IsSerializable flag. Also if it has IsWriteOnce then it also returns false, because the UndoStack would not be able to change the value. If false is returned then the property is not preserved across undo/redo. For transient properties returning false can save lots of memory in the undo stack. |
![]() | MemberwiseClone() | (Inherited from Object.) |
![]() | RemoveLink(GraphLink^) | Called during Apply if a link has to be added back to the graph. You can override this but you must call base.RemoveLink. |
![]() | RemoveNode(GraphNode^) | Called during Apply if a node has to be removed from to the graph. You can override this but you must call base.RemoveNode. |
![]() | ToString() | (Inherited from Object.) |
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.




