Package com.nt.udc.aggregator.table
Class AggrTable
java.lang.Object
com.nt.udc.aggregator.AggregatorModule
com.nt.udc.aggregator.table.AggrTable
Currently, this class handles the table functionality of an
aggregator. For the most part, this is just table-related
procedures, including access, initialization and shutdown.
-
Field Summary
Fields inherited from class com.nt.udc.aggregator.AggregatorModule
config, logger
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
Closes the tableboolean
containsKey
(NARKey key) Returns whether a given key exists in the tableGets a NAR from the table according to the given key.protected void
This method should obtain the necessary information from the config class, in order to configure the module.boolean
keys()
Keys of all the records in the tablevoid
open()
Opens the table.void
Puts a NAR into the table, according to the given key.int[]
Returns the fields needed by a new record, where those fields are managed by this object.Removes a NAR from the table, and returns the element at the key.void
shutdown()
Shuts down this object.
-
Constructor Details
-
AggrTable
Creates the base object.- Parameters:
table
- Active record storage table.
-
-
Method Details
-
getConfigData
protected void getConfigData()Description copied from class:AggregatorModule
This method should obtain the necessary information from the config class, in order to configure the module.- Specified by:
getConfigData
in classAggregatorModule
-
open
public void open()Opens the table. -
close
public void close()Closes the table -
recordInitFields
public int[] recordInitFields()Returns the fields needed by a new record, where those fields are managed by this object.- Specified by:
recordInitFields
in classAggregatorModule
- Returns:
- Field ID's to include in a new record that is inserted into the table.
-
shutdown
public void shutdown()Shuts down this object.- Specified by:
shutdown
in classAggregatorModule
-
get
Gets a NAR from the table according to the given key.- Parameters:
key
- Key of the NAR in the table- Returns:
- NAR, according to the given key
-
put
Puts a NAR into the table, according to the given key.- Parameters:
key
- Index of the NARrecord
- NAR to put
-
remove
Removes a NAR from the table, and returns the element at the key.- Parameters:
key
- Key of the record to remove ggerIfc.SF_RES_ERR_ENT_CREATE- Returns:
- record at the key, or NULL if no record was found
-
keys
Keys of all the records in the table- Returns:
- Enumeration of all the keys
-
containsKey
Returns whether a given key exists in the table- Parameters:
key
- Key to look for- Returns:
- true, if the key exists
-
isHealthy
public boolean isHealthy()
-