Class DefaultMOMutableTableModel<R extends MOTableRow>

    • Constructor Detail

      • DefaultMOMutableTableModel

        public DefaultMOMutableTableModel()
    • Method Detail

      • getRows

        public List<MOTableRow> getRows​(org.snmp4j.smi.OID lowerBound,
                                        org.snmp4j.smi.OID upperBoundEx)
        Returns a lexicographic ordered list of the rows in the specified index range.
        Parameters:
        lowerBound - the lower bound index (inclusive) for the rows in the returned list.
        upperBoundEx - the upper bound index (exclusive) for the rows in the returned list.
        Returns:
        the possibly empty lexicographically ordered List of rows of this table model in the specified index range. Modifications to the list will not affect the underlying table model, although modifications to the row elements will.
      • getRows

        public List<R> getRows​(org.snmp4j.smi.OID lowerBound,
                               org.snmp4j.smi.OID upperBoundEx,
                               MOTableRowFilter<R> filter)
        Returns a lexicographic ordered list of the rows in the specified index range that match the supplied filter.
        Parameters:
        lowerBound - the lower bound index (inclusive) for the rows in the returned list.
        upperBoundEx - the upper bound index (exclusive) for the rows in the returned list.
        filter - the filter to exclude rows in the range from the returned
        Returns:
        the possibly empty lexicographically ordered List of rows of this table model in the specified index range. Modifications to the list will not affect the underlying table model, although modifications to the row elements will.
      • removeRow

        public R removeRow​(org.snmp4j.smi.OID index)
        Description copied from interface: MOMutableTableModel
        Removes the row with the specified index from the table and returns it.
        Specified by:
        removeRow in interface MOMutableTableModel<R extends MOTableRow>
        Parameters:
        index - the row index of the row to remove.
        Returns:
        the removed row or null if the table did not contain such a row.
      • removeRows

        public void removeRows​(org.snmp4j.smi.OID lowerBoundIncl,
                               org.snmp4j.smi.OID upperBoundExcl)
      • clear

        public List<R> clear​(MOTableRowFilter<R> filter)
        Remove all rows that do not match the given filter criteria from the model.
        Specified by:
        clear in interface MOMutableTableModel<R extends MOTableRow>
        Parameters:
        filter - the MOTableRowFilter that filters out the rows to delete.
        Returns:
        the number of removed rows.
      • iterator

        public Iterator<R> iterator​(MOTableRowFilter<R> filter)
        Returns an iterator over all rows in this table that pass the given filter. If the table might be modified while the iterator is used, it is recommended to synchronize on this model while iterating.
        Parameters:
        filter - a MOTableRowFilter instance that defines the rows to return.
        Returns:
        an Iterator.
      • setColumnCount

        public void setColumnCount​(int columnCount)
      • freeRow

        public void freeRow​(R row)
        Description copied from interface: MOTableRowFactory
        Frees resources associated with the supplied row which is to be deleted.
        Specified by:
        freeRow in interface MOTableRowFactory<R extends MOTableRow>
        Parameters:
        row - a MOTableRow that has been created using this factory and is now to be deleted (removed from the associated table).
      • fireTableModelChanged

        protected void fireTableModelChanged​(MOTableModelEvent event)
      • addRow

        public R addRow​(R row)
        Description copied from interface: MOMutableTableModel
        Adds a row to the table. If a row with the same index already exists it will be replaced and returned.
        Specified by:
        addRow in interface MOMutableTableModel<R extends MOTableRow>
        Overrides:
        addRow in class DefaultMOTableModel<R extends MOTableRow>
        Parameters:
        row - the MOTableRow instance to add.
        Returns:
        the previous row with the specified index or null if it did not have one.