Class FlexibleAggrTable

java.lang.Object
com.nt.udc.flexibleAggregator.table.FlexibleAggrTable

public class FlexibleAggrTable extends Object
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 Details

    • tableName

      public static String tableName
  • Constructor Details

    • FlexibleAggrTable

      public FlexibleAggrTable(LoggerIfc loggerObj, Factory factory, File scratchDir, int compressionThresholdSetting, String fileNameExtender)
      Creates the base object.
  • Method Details

    • open

      public void open()
      Opens the table.
    • close

      public void close()
      Closes the table
    • shutdown

      public void shutdown()
      Shuts down this object.
    • put

      public void put(FlexibleNARKey key, NAR record)
      Puts a NAR into the table, according to the given key.
      Parameters:
      key - Index of the NAR
      record - NAR to put
    • remove

      public NAR remove(FlexibleNARKey key)
      Removes a NAR from the table, and returns the element at the key. Only ever allow returning the NAR when removing, otherwise there would be synchronization issues.
      Parameters:
      key - Key of the record to remove
      Returns:
      record at the key, or NULL if no record was found
    • removeDelayedNARParsing

      public Object removeDelayedNARParsing(FlexibleNARKey key)
      Clone of remove(), but with delayed NAR Parsing. For use by MTAggrDispatcher ONLY.
      Parameters:
      key -
      Returns:
      whatever FileHashTable.removeDelayedNARParsing returns, either NAR or ByteArray object.
    • keys

      public Enumeration keys()
      Keys of all the records in the table
      Returns:
      Enumeration of all the keys
    • containsKey

      public boolean containsKey(FlexibleNARKey key)
      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()
    • get

      public NAR get(FlexibleNARKey key)
      Don't use this. Use remove*() for normal operations. (MXAggrDispatcher is using this for specific data recovery scenerios...)
      Parameters:
      key -
      Returns: