|
org.netbeans.modules.diff/1 1.18.0 42 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.netbeans.api.diff.DiffController
public final class DiffController
Encapsulates a single Diff window that displays differences between two files (sources).
| Nested Class Summary | |
|---|---|
static class |
DiffController.DiffPane
Enumerates Base (left) and Modified (right) panes of a Diff view for setLocation() method |
static class |
DiffController.LocationType
Enumerates types of location for setLocation() method. |
| Field Summary | |
|---|---|
static String |
PROP_DIFFERENCES
Property change that indicates that set of differences OR the current difference changed. |
| Method Summary | |
|---|---|
void |
addPropertyChangeListener(PropertyChangeListener listener)
Adds a property change listener. |
static DiffController |
create(StreamSource base,
StreamSource modified)
Creates a Diff Controller for supplied left and right sources. |
int |
getDifferenceCount()
Gets total number of Differences between sources currently displayed in the Diff view. |
int |
getDifferenceIndex()
Gets the current (highlighted) difference in the Diff view. |
JComponent |
getJComponent()
Intializes the Controller and creates visual presenter of the Diff. |
void |
removePropertyChangeListener(PropertyChangeListener listener)
Removes a property change listener. |
void |
setLocation(DiffController.DiffPane pane,
DiffController.LocationType type,
int location)
Ensure the requested location in the Diff view is visible on screen. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String PROP_DIFFERENCES
| Method Detail |
|---|
public static DiffController create(StreamSource base, StreamSource modified) throws IOException
base - defines content of the Base Diff panemodified - defines content of the Modified (possibly editable) Diff pane
IOException - when the reading from input streams fails.public void setLocation(DiffController.DiffPane pane, DiffController.LocationType type, int location)
pane - defines which pane the location parameter refers totype - defines the location parameter, see belowlocation - depending on the type parameter this defines either a line number or a Difference index, both 0-based
IllegalArgumentException - if location parameter is out of range for the given pane and location typepublic JComponent getJComponent()
public int getDifferenceCount()
public int getDifferenceIndex()
public void addPropertyChangeListener(PropertyChangeListener listener)
listener - property change listenerpublic void removePropertyChangeListener(PropertyChangeListener listener)
listener - property change listener
|
org.netbeans.modules.diff/1 1.18.0 42 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||