Class CRCollection

java.lang.Object
javax.swing.table.AbstractTableModel
de.kappich.pat.gnd.extLocRef.CRCollection
All Implemented Interfaces:
java.io.Serializable, javax.swing.table.TableModel

public class CRCollection
extends javax.swing.table.AbstractTableModel
Diese Klasse verkapselt eine Liste von ComposedReferences und ist zugleich ein TableModel.
See Also:
Serialized Form
  • Field Summary

    Fields inherited from class javax.swing.table.AbstractTableModel

    listenerList
  • Constructor Summary

    Constructors
    Constructor Description
    CRCollection()  
    CRCollection​(java.util.List<ComposedReference> composedReferences)  
  • Method Summary

    Modifier and Type Method Description
    boolean add​(ComposedReference composedReference)  
    void clear()  
    boolean contains​(ComposedReference reference)  
    ComposedReference get​(int index)  
    int getColumnCount()  
    java.lang.String getColumnName​(int columnIndex)  
    java.util.List<ComposedReference> getComposedReferences()  
    int getRowCount()  
    java.lang.Object getValueAt​(int rowIndex, int columnIndex)  
    boolean isEmpty()  
    boolean moveUpwards​(int[] indices)
    Diese Methode ändert die Reihenfolge der EOR.
    boolean remove​(ComposedReference composedReference)  
    int size()  
    java.lang.String toString()  

    Methods inherited from class javax.swing.table.AbstractTableModel

    addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getColumnClass, getListeners, getTableModelListeners, isCellEditable, removeTableModelListener, setValueAt

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • CRCollection

      public CRCollection()
    • CRCollection

      public CRCollection​(java.util.List<ComposedReference> composedReferences)
  • Method Details

    • add

      public boolean add​(ComposedReference composedReference)
    • remove

      public boolean remove​(ComposedReference composedReference)
    • moveUpwards

      public boolean moveUpwards​(int[] indices)
      Diese Methode ändert die Reihenfolge der EOR. Alle EOR, deren Indizes übergeben werden, werden in der Reihenfolge um eins naoch oben verschoben. Dazu darf der Index 0 nicht in dem Array enthalten sein. Die Indizes müssen nicht sortiert sein: das macht die Methode selber.
      Parameters:
      indices - Indizes
      Returns:
    • get

      public ComposedReference get​(int index)
    • size

      public int size()
    • isEmpty

      public boolean isEmpty()
    • clear

      public void clear()
    • getComposedReferences

      public java.util.List<ComposedReference> getComposedReferences()
    • contains

      public boolean contains​(ComposedReference reference)
    • getRowCount

      public int getRowCount()
    • getColumnCount

      public int getColumnCount()
    • getColumnName

      public java.lang.String getColumnName​(int columnIndex)
      Specified by:
      getColumnName in interface javax.swing.table.TableModel
      Overrides:
      getColumnName in class javax.swing.table.AbstractTableModel
    • getValueAt

      @Nullable public java.lang.Object getValueAt​(int rowIndex, int columnIndex)
    • toString

      public java.lang.String toString()
      Overrides:
      toString in class java.lang.Object