public class RFListModel<E> extends javax.swing.AbstractListModel implements IListModel<E>
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CLAZZ
Class name.
|
static long |
serialVersionUID
This is the current unique serial version UID.
|
Constructor and Description |
---|
RFListModel()
Creates a new RF list model.
|
Modifier and Type | Method and Description |
---|---|
void |
add(int index_,
E element_)
Adds an element at the index to the list.
|
void |
addElement(E element_)
Adds an element to the end of the list.
|
void |
clear()
Clears all element from the list.
|
boolean |
contains(E element_)
Queries if the corresponding element is in the model (true) or
not (false).
|
protected void |
fireContentsChanged(java.lang.Object source_,
int index0_,
int index1_) |
protected void |
fireIntervalAdded(java.lang.Object source_,
int index0_,
int index1_) |
protected void |
fireIntervalRemoved(java.lang.Object source_,
int index0_,
int index1_) |
E |
get(int index_)
Gets the current element at the position of index.
|
E |
getElementAt(int index_) |
int |
getSize() |
boolean |
isEmpty()
Queries if the list is empty.
|
boolean |
remove(E element_)
Removes the element from the model.
|
E |
remove(int index_)
Removes element at the position of index and returns the deleted element.
|
int |
size()
Returns the size of the model.
|
java.lang.String |
toString() |
addListDataListener, getListDataListeners, getListeners, removeListDataListener
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
addListDataListener, removeListDataListener
public static final long serialVersionUID
public static final java.lang.String CLAZZ
public RFListModel()
java.util.List
.public void add(int index_, E element_)
IListModel
add
in interface IListModel<E>
index_
- The index to add the element.element_
- The element to add to the model.public void addElement(E element_)
IListModel
addElement
in interface IListModel<E>
element_
- The element to add to the model.public void clear()
IListModel
clear
in interface IListModel<E>
public boolean contains(E element_)
IListModel
contains
in interface IListModel<E>
element_
- Is the element to query for.public E get(int index_)
IListModel
get
in interface IListModel<E>
index_
- Is the index. Should be in the range of the model indexes.
If it is outside a IllegalArgumentException will be thrown
or a null value is returned.public boolean isEmpty()
IListModel
isEmpty
in interface IListModel<E>
public boolean remove(E element_)
IListModel
remove
in interface IListModel<E>
element_
- The element to be deleted.public E remove(int index_)
IListModel
remove
in interface IListModel<E>
index_
- The index in the model.public int size()
IListModel
size
in interface IListModel<E>
public E getElementAt(int index_)
getElementAt
in interface javax.swing.ListModel
public int getSize()
getSize
in interface javax.swing.ListModel
protected void fireContentsChanged(java.lang.Object source_, int index0_, int index1_)
fireContentsChanged
in class javax.swing.AbstractListModel
protected void fireIntervalAdded(java.lang.Object source_, int index0_, int index1_)
fireIntervalAdded
in class javax.swing.AbstractListModel
protected void fireIntervalRemoved(java.lang.Object source_, int index0_, int index1_)
fireIntervalRemoved
in class javax.swing.AbstractListModel
public java.lang.String toString()
toString
in class java.lang.Object
14-September-2016 18:23 Deutsches Elektronen-Synchrotron DESY in der Helmholtz-Gemeinschaft