public class UndoRedoEditEvent
extends java.util.EventObject
An event indicating the kind of operation occurred: undo or redo.
Modifier and Type | Field and Description |
---|---|
protected java.lang.String |
myNewText |
protected java.lang.String |
myOldText |
protected short |
myType |
static short |
REDO |
static short |
UNDO |
Constructor and Description |
---|
UndoRedoEditEvent(java.lang.Object source,
short type,
java.lang.String oldText,
java.lang.String newText)
Constructs an UndoableEditEvent object.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getNewText()
Returns the new text.
|
java.lang.String |
getOldText()
Returns the previous text.
|
short |
getType()
Returns the edit operation identifier value.
|
java.lang.String |
toString()
Returns a
String representation of this UndoRedoEditEvent . |
public static final short UNDO
public static final short REDO
protected transient short myType
protected transient java.lang.String myOldText
protected transient java.lang.String myNewText
public UndoRedoEditEvent(java.lang.Object source, short type, java.lang.String oldText, java.lang.String newText)
source
- the Object that originated the event
(typically this
)type
- type of operation done (undo or redo)oldText
- text before the operationnewText
- text after the operationpublic short getType()
public java.lang.String getOldText()
public java.lang.String getNewText()
public java.lang.String toString()
String
representation of this UndoRedoEditEvent
.toString
in class java.util.EventObject
String
representation of this UndoRedoEditEvent