Interface ListModel<T>

    • Method Detail

      • elementAt

        T elementAt​(int index)
             throws java.lang.IndexOutOfBoundsException
        Returns the element at position index.
        Parameters:
        index - position of the element to get
        Returns:
        the element at position index
        Throws:
        java.lang.IndexOutOfBoundsException - if there is no element at position index
      • getElements

        java.util.List<T> getElements()
        Returns all elements.
        Returns:
        list containing all elements
      • isRemovable

        boolean isRemovable​(int index)
                     throws java.lang.IndexOutOfBoundsException
        Returns whether the element at position index is removable or not.
        Parameters:
        index - position of the element
        Returns:
        true if the element is removable, false otherwise
        Throws:
        java.lang.IndexOutOfBoundsException - if there is no element at position index
      • isMovable

        boolean isMovable​(int index)
                   throws java.lang.IndexOutOfBoundsException
        Returns whether the element at position index is movable or not.
        Parameters:
        index - position of the element
        Returns:
        true if the element is movable, false otherwise
        Throws:
        java.lang.IndexOutOfBoundsException - if there is no element at position index
      • isEditable

        boolean isEditable()
        Returns whether this list is marked as _editable_ or not.
        Returns:
        true if this list is marked as editable, false otherwise
      • size

        int size()
        Returns the size of this list i.e. the number of elements stored.
        Returns:
        this list's size
      • isEmpty

        boolean isEmpty()