javax.swing.text
public class AbstractDocument.DefaultDocumentEvent extends CompoundEdit implements DocumentEvent
Document is beeing modified.
| Constructor Summary | |
|---|---|
| DefaultDocumentEvent(int offset, int length, EventType type)
Creates a new DefaultDocumentEvent.
| |
| Method Summary | |
|---|---|
| boolean | addEdit(UndoableEdit edit)
Adds an UndoableEdit to this DocumentEvent. |
| ElementChange | getChange(Element elem)
Returns the changes for an element.
|
| Document | getDocument()
Returns the document that has been modified.
|
| int | getLength()
Returns the length of the modification.
|
| int | getOffset()
Returns the start offset of the modification.
|
| EventType | getType()
Returns the type of the modification.
|
| String | toString()
Returns a String description of the change event. |
DefaultDocumentEvent.
Parameters: offset the starting offset of the change length the length of the change type the type of change
DocumentEvent. If this
edit is an instance of ElementEdit, then this record can
later be fetched by calling DefaultDocumentEvent.
Parameters: edit the undoable edit to add
Parameters: elem the element for which the changes are requested
Returns: the changes for elem or null if
elem has not been changed
Returns: the document that has been modified
Returns: the length of the modification
Returns: the start offset of the modification
Returns: the type of the modification