public class GraphSelectionEvent
extends java.util.EventObject
GraphSelectionListener,
GraphSelectionModel,
Serialized Form| Modifier and Type | Field and Description |
|---|---|
protected boolean[] |
areNew
For each cell identifies whether or not that cell is newly selected.
|
protected java.lang.Object[] |
cells
Cells this event represents.
|
| Constructor and Description |
|---|
GraphSelectionEvent(java.lang.Object source,
java.lang.Object[] cells,
boolean[] areNew)
Represents a change in the selection of a GraphSelectionModel.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
cloneWithSource(java.lang.Object newSource)
Returns a copy of the receiver, but with the source being newSource.
|
java.lang.Object |
getCell()
Returns the first cell.
|
java.lang.Object[] |
getCells()
Returns the cells that have been added or removed from the selection.
|
boolean |
isAddedCell()
Returns true if the first cell has been added to the selection, a return
value of false means the first cell has been removed from the selection.
|
boolean |
isAddedCell(int index)
Returns true if the cell identified by
index was added to
the selection. |
boolean |
isAddedCell(java.lang.Object cell)
Returns true if the cell identified by cell was added to the selection.
|
protected java.lang.Object[] cells
protected boolean[] areNew
public GraphSelectionEvent(java.lang.Object source,
java.lang.Object[] cells,
boolean[] areNew)
cells identifies the cells that have been either added or
removed from the selection.source - source of eventcells - the paths that have changed in the selectionareNew - for each cell, defines whether or not that cell is newly
selectedpublic java.lang.Object[] getCells()
public java.lang.Object getCell()
public boolean isAddedCell()
public boolean isAddedCell(java.lang.Object cell)
cell - the cell that is to be indicated as newly selected or nottrue if the specified cell is newly selectedpublic boolean isAddedCell(int index)
index was added to
the selection. A return value of false means the cell was in the
selection but is no longer in the selection. This will raise an exception
if index < 0 || >=getPaths .length.index - the index of areNew of the cell that is to be
indicated as newly selected or notpublic java.lang.Object cloneWithSource(java.lang.Object newSource)
newSource - the new event sourceCopyright (C) 2001-2008 Gaudenz Alder. All rights reserved.