public class DefaultChangeListener extends java.lang.Object implements ChangeListener
CVS_ID| Constructor and Description |
|---|
DefaultChangeListener(java.io.PrintWriter out)
Creates a new default change listener that will write to the given
writer.
|
DefaultChangeListener(java.io.PrintWriter out,
boolean debug)
Creates a new default change listener that will write to the given
writer.
|
| Modifier and Type | Method and Description |
|---|---|
void |
onChangeEnd()
Invoked after a change finished.
|
void |
onChangeStart(int leftLine,
int leftLen,
int rightLine,
int rightLen)
Invoked before a change starts.
|
void |
onDeleted(int leftLine,
int rightLine,
Document.Element text)
Invoked for a deleted element
|
void |
onDocumentsEnd(Document left,
Document right)
Invoked after the iteration over the changes finished.
|
void |
onDocumentsStart(Document left,
Document right)
Invoked before the iteration over the changes start.
|
void |
onInserted(int leftLine,
int rightLine,
Document.Element text)
Invoked for an inserted element
|
void |
onUnmodified(int leftLine,
int rightLine,
Document.Element text)
Invoked for an unmodified element
|
public DefaultChangeListener(java.io.PrintWriter out)
out - the writerpublic DefaultChangeListener(java.io.PrintWriter out,
boolean debug)
true the line numbers are also included
in the output.out - the writerdebug - flagpublic void onDocumentsStart(Document left, Document right)
onDocumentsStart in interface ChangeListenerleft - the left documentright - the right documentpublic void onDocumentsEnd(Document left, Document right)
onDocumentsEnd in interface ChangeListenerleft - the left documentright - the right documentpublic void onChangeStart(int leftLine,
int leftLen,
int rightLine,
int rightLen)
onChangeStart in interface ChangeListenerleftLine - the index of the left element of this change.leftLen - the number of changed left elements.rightLine - the index of the right element of this change.rightLen - the number of changed right elements.public void onChangeEnd()
onChangeEnd in interface ChangeListenerpublic void onUnmodified(int leftLine,
int rightLine,
Document.Element text)
onUnmodified in interface ChangeListenerleftLine - the index of the left elementrightLine - the index of the right elementtext - the elementpublic void onDeleted(int leftLine,
int rightLine,
Document.Element text)
onDeleted in interface ChangeListenerleftLine - the index of the left elementrightLine - the index of the right elementtext - the elementpublic void onInserted(int leftLine,
int rightLine,
Document.Element text)
onInserted in interface ChangeListenerleftLine - the index of the left elementrightLine - the index of the right elementtext - the elementCopyright © 2010 - 2023 Adobe. All Rights Reserved