Package org.eclipse.text.undo
Class DocumentUndoEvent
java.lang.Object
org.eclipse.text.undo.DocumentUndoEvent
Describes document changes initiated by undo or redo.
 
Clients are not supposed to subclass or create instances of this class.
- Since:
- 3.2
- See Also:
- Restriction:
- This class is not intended to be subclassed by clients.
- Restriction:
- This class is not intended to be instantiated by clients.
- 
Field SummaryFieldsModifier and TypeFieldDescriptionstatic final intIndicates that the described document event is about to be redone.static final intIndicates that the described document event is about to be undone.static final intIndicates that the described document event is a compound undo or redo event.static final intIndicates that the described document event has been redone.static final intIndicates that the described document event has been undone.
- 
Method SummaryModifier and TypeMethodDescriptionReturns the changed document.intReturns the type of event that is occurring.intReturns the offset of the change.Returns the text that has been replaced.Returns the source that triggered this event.getText()Returns the text that has been inserted.booleanReturns whether the change was a compound change or not.
- 
Field Details- 
ABOUT_TO_UNDOpublic static final int ABOUT_TO_UNDOIndicates that the described document event is about to be undone.- See Also:
 
- 
ABOUT_TO_REDOpublic static final int ABOUT_TO_REDOIndicates that the described document event is about to be redone.- See Also:
 
- 
UNDONEpublic static final int UNDONEIndicates that the described document event has been undone.- See Also:
 
- 
REDONEpublic static final int REDONEIndicates that the described document event has been redone.- See Also:
 
- 
COMPOUNDpublic static final int COMPOUNDIndicates that the described document event is a compound undo or redo event.- See Also:
 
 
- 
- 
Method Details- 
getDocumentReturns the changed document.- Returns:
- the changed document
 
- 
getOffsetpublic int getOffset()Returns the offset of the change.- Returns:
- the offset of the change
 
- 
getTextReturns the text that has been inserted.- Returns:
- the text that has been inserted
 
- 
getPreservedTextReturns the text that has been replaced.- Returns:
- the text that has been replaced
 
- 
getEventTypepublic int getEventType()Returns the type of event that is occurring.- Returns:
- the bit mask that indicates the type (or types) of the event
 
- 
getSourceReturns the source that triggered this event.- Returns:
- the source that triggered this event.
 
- 
isCompoundpublic boolean isCompound()Returns whether the change was a compound change or not.- Returns:
- trueif the undo or redo change is a compound change,- falseif it is not
 
 
-