public class DefaultListTwinsModel extends Object implements JListTwinsModel
| Constructor and Description |
|---|
DefaultListTwinsModel(Object[] values,
int[] selected) |
| Modifier and Type | Method and Description |
|---|---|
void |
addLeftListDataListener(ListDataListener l)
Adds a listener to the list that's notified each time a change
to the data model occurs.
|
void |
addRightListDataListener(ListDataListener l) |
Object |
getLeftElementAt(int index) |
int |
getLeftSize()
Returns the length of the list.
|
Object |
getRightElementAt(int index) |
int |
getRightSize() |
void |
moveAllLeft() |
void |
moveAllRight() |
void |
moveLeft(int rightIndex) |
void |
moveRight(int rightIndex) |
void |
removeLeftListDataListener(ListDataListener l)
Removes a listener from the list that's notified each time a
change to the data model occurs.
|
void |
removeRightListDataListener(ListDataListener l) |
public DefaultListTwinsModel(Object[] values, int[] selected)
public int getLeftSize()
JListTwinsModelgetLeftSize in interface JListTwinsModelpublic int getRightSize()
getRightSize in interface JListTwinsModelpublic Object getLeftElementAt(int index)
getLeftElementAt in interface JListTwinsModelpublic Object getRightElementAt(int index)
getRightElementAt in interface JListTwinsModelpublic void addLeftListDataListener(ListDataListener l)
JListTwinsModeladdLeftListDataListener in interface JListTwinsModell - the ListDataListener to be addedpublic void addRightListDataListener(ListDataListener l)
addRightListDataListener in interface JListTwinsModelpublic void removeLeftListDataListener(ListDataListener l)
JListTwinsModelremoveLeftListDataListener in interface JListTwinsModell - the ListDataListener to be removedpublic void removeRightListDataListener(ListDataListener l)
removeRightListDataListener in interface JListTwinsModelpublic void moveAllLeft()
moveAllLeft in interface JListTwinsModelpublic void moveAllRight()
moveAllRight in interface JListTwinsModelpublic void moveLeft(int rightIndex)
moveLeft in interface JListTwinsModelpublic void moveRight(int rightIndex)
moveRight in interface JListTwinsModelCopyright © 2022 vpc open source initiative. All rights reserved.