All Packages Class Hierarchy This Package Previous Next Index
Class com.sun.java.swing.DefaultListSelectionModel
java.lang.Object
|
+----com.sun.java.swing.DefaultListSelectionModel
- public class DefaultListSelectionModel
- extends Object
- implements ListSelectionModel, Cloneable, Serializable
-
isAdjusting
-
-
listenerList
-
-
value
-
-
DefaultListSelectionModel()
-
-
addListSelectionListener(ListSelectionListener)
-
-
addSelectionInterval(int, int)
-
-
clearSelection()
-
-
clone()
- Returns a clone of the reciever with the same selection.
-
fireValueChanged(boolean)
- Notify listeners that we are beginning or ending a
series of value changes
-
fireValueChanged(int, int)
- Notify ListSelectionListeners that the value of the selection,
in the closed interval firstIndex,lastIndex, has changed.
-
fireValueChanged(int, int, boolean)
-
-
getAnchorSelectionIndex()
-
-
getLeadSelectionIndex()
-
-
getMaxSelectionIndex()
-
-
getMinSelectionIndex()
-
-
getValueIsAdjusting()
-
-
insertIndexInterval(int, int, boolean)
-
Insert length indices beginning before/after index.
-
isSelectedIndex(int)
-
-
isSelectionEmpty()
-
-
removeIndexInterval(int, int)
-
Remove the indices in the interval index0,index1 (inclusive) from
the selection model.
-
removeListSelectionListener(ListSelectionListener)
-
-
removeSelectionInterval(int, int)
-
-
setSelectionInterval(int, int)
-
-
setValueIsAdjusting(boolean)
-
-
toString()
-
value
protected BitSet value
listenerList
protected EventListenerList listenerList
isAdjusting
protected boolean isAdjusting
DefaultListSelectionModel
public DefaultListSelectionModel()
getAnchorSelectionIndex
public int getAnchorSelectionIndex()
getLeadSelectionIndex
public int getLeadSelectionIndex()
getMinSelectionIndex
public int getMinSelectionIndex()
getMaxSelectionIndex
public int getMaxSelectionIndex()
isSelectedIndex
public boolean isSelectedIndex(int index)
isSelectionEmpty
public boolean isSelectionEmpty()
addListSelectionListener
public void addListSelectionListener(ListSelectionListener l)
removeListSelectionListener
public void removeListSelectionListener(ListSelectionListener l)
fireValueChanged
protected void fireValueChanged(boolean isAdjusting)
- Notify listeners that we are beginning or ending a
series of value changes
fireValueChanged
protected void fireValueChanged(int firstIndex,
int lastIndex)
- Notify ListSelectionListeners that the value of the selection,
in the closed interval firstIndex,lastIndex, has changed.
fireValueChanged
protected void fireValueChanged(int firstIndex,
int lastIndex,
boolean isAdjusting)
- Parameters:
- firstIndex - The first index in the interval.
- index1 - The last index in the interval.
- isAdjusting - Whether we're issuing a rapid stream of events
- See Also:
- EventListenerList
clearSelection
public void clearSelection()
setSelectionInterval
public void setSelectionInterval(int index0,
int index1)
addSelectionInterval
public void addSelectionInterval(int index0,
int index1)
removeSelectionInterval
public void removeSelectionInterval(int index0,
int index1)
insertIndexInterval
public void insertIndexInterval(int index,
int length,
boolean before)
- Insert length indices beginning before/after index. This is typically
called to sync the selection model with a corresponding change
in the data model.
removeIndexInterval
public void removeIndexInterval(int index0,
int index1)
- Remove the indices in the interval index0,index1 (inclusive) from
the selection model. This is typically called to sync the selection
model width a corresponding change in the data model. Note
that (as always) index0 need not be <= index1.
setValueIsAdjusting
public void setValueIsAdjusting(boolean b)
getValueIsAdjusting
public boolean getValueIsAdjusting()
toString
public String toString()
- Overrides:
- toString in class Object
clone
public Object clone() throws CloneNotSupportedException
- Returns a clone of the reciever with the same selection.
listenerLists are not duplicated.
- Throws: CloneNotSupportedException
- if the receiver does not
both (a) implement the Cloneable interface and (b) define a
clone
method.
- Overrides:
- clone in class Object
All Packages Class Hierarchy This Package Previous Next Index