com.adventnet.utils.agent
Interface TableModelListener

All Known Subinterfaces:
TableModelListenerExt
All Known Implementing Classes:
VaclTableModelListener

public interface TableModelListener

This interface is used for handling tables in SNMP when user needs the choice of handling the table entries rather than the SNMP agent holding it them in memory.


Method Summary
 void addRow(TableEntry entry)
          When the manager is trying to add a row in the table, this method will be called.
 void deleteRow(int[] inst)
          When the manager is trying to delete a row in the table, this method will be called.
 TableEntry get(int[] inst)
          To get the entry for the given row (identified by the instance).
 TableEntry getFirstEntry()
          To get the first entry in the table.
 TableEntry getNext(int[] inst)
          To get the next entry for the given row (identified by the instance).
 java.util.Vector getTableElements()
          To get the table elements.
 void setTableElements(java.util.Vector tableElements)
          To set the table elements.
 

Method Detail

get

TableEntry get(int[] inst)
To get the entry for the given row (identified by the instance).

Parameters:
inst - The instance Value.
Returns:
instance of TableEntry interface with the entry information. Otherwise null.

getNext

TableEntry getNext(int[] inst)
To get the next entry for the given row (identified by the instance).

Parameters:
inst - The instance Value.
Returns:
instance of TableEntry interface with the entry information. Otherwise null.

getFirstEntry

TableEntry getFirstEntry()
To get the first entry in the table.

Returns:
instance of TableEntry interface with the entry information. Otherwise null.

addRow

void addRow(TableEntry entry)
            throws java.lang.Exception
When the manager is trying to add a row in the table, this method will be called.

Parameters:
entry - the table entry class instance.
Throws:
java.lang.Exception - If the entry given is wrong Exceptions will be thrown.

deleteRow

void deleteRow(int[] inst)
               throws java.lang.Exception
When the manager is trying to delete a row in the table, this method will be called.

Parameters:
inst - the instance Value.
Throws:
java.lang.Exception - If the entry given is wrong Exceptions will be thrown.

setTableElements

void setTableElements(java.util.Vector tableElements)
To set the table elements.

Parameters:
tableElements - the collection of TableEntry instances.

getTableElements

java.util.Vector getTableElements()
To get the table elements.

Returns:
the Vector instance with collection of TableEntry instances.