Package org.gvsig.utils.listManager
Class DefaultListModel
java.lang.Object
javax.swing.AbstractListModel
org.gvsig.utils.listManager.DefaultListModel
- All Implemented Interfaces:
Serializable,ListModel,ListModel
Implementación por defecto de ListModel
- Author:
- Fernando González Cortés
- See Also:
-
Field Summary
Fields inherited from class javax.swing.AbstractListModel
listenerList -
Constructor Summary
ConstructorsConstructorDescriptionDefaultListModel(boolean down) Crea un nuevo DefaultListModel con un parámetro que indica si la lista se crea en el orden que se van introcuciendo(true) o al contrario. -
Method Summary
Modifier and TypeMethodDescriptionvoidAppends the specified element to the end of this VectorgetElementAt(int arg0) Obtains the objects that are in the modelintgetSize()voidInserts the specified element at the specified position in this Vector.remove(int i) Removes the element at the specified position in this Vector. shifts any subsequent elements to the left (subtracts one from their indices).Methods inherited from class javax.swing.AbstractListModel
addListDataListener, fireContentsChanged, fireIntervalAdded, fireIntervalRemoved, getListDataListeners, getListeners, removeListDataListenerMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface javax.swing.ListModel
addListDataListener, removeListDataListener
-
Constructor Details
-
DefaultListModel
public DefaultListModel(boolean down) Crea un nuevo DefaultListModel con un parámetro que indica si la lista se crea en el orden que se van introcuciendo(true) o al contrario.
-
-
Method Details
-
remove
Description copied from interface:ListModelRemoves the element at the specified position in this Vector. shifts any subsequent elements to the left (subtracts one from their indices). Returns the element that was removed from the Vector.- Specified by:
removein interfaceListModel- Parameters:
i- Índice del elemento que se quiere eliminar- Returns:
- Objeto eliminado
- Throws:
ArrayIndexOutOfBoundsException- Si el índice está fuera del array- See Also:
-
insertAt
Description copied from interface:ListModelInserts the specified element at the specified position in this Vector. Shifts the element currently at that position (if any) and any subsequent elements to the right (adds one to their indices). -
getSize
public int getSize() -
getElementAt
- Specified by:
getElementAtin interfaceListModel- See Also:
-
add
Description copied from interface:ListModelAppends the specified element to the end of this Vector -
getObjects
Description copied from interface:ListModelObtains the objects that are in the model- Specified by:
getObjectsin interfaceListModel- Returns:
- Vector with the objetos
- See Also:
-