Class TdbCompressionContext

java.lang.Object
com.tietoenator.trip.jxp.database.TdbCompressionContext
All Implemented Interfaces:
com.tietoenator.trip.jxp.internal.utils.DOMSink

public class TdbCompressionContext extends Object implements com.tietoenator.trip.jxp.internal.utils.DOMSink
This class provides contextual information for a database compression operation via the Compress method on the TdbDatabaseDesign class. Individual iterations of compression (i.e. calls within a complete cycle) are tied together using an instance of this class.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Constructor, create a new blank context.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Check whether the compression operation is maintaining record IDs.
    int
    Retrieve the total number of records to be compressed.
    Retrieve the new filename of the database's BAF.
    int
    Retrieve the progress made to date by the compression operation.
    boolean
    Check if the database to be compressed contains modified unindexed records.
    boolean
    Check whether the compression operation has completed on the server
    boolean
    Check whether the compression operation has been started on the server
    void
    setKeepRecordIds(boolean keep)
    Establish whether to maintain record IDs during compression.
    void
    setNewName(String filename)
    Set the new filename of the database's BAF.

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • TdbCompressionContext

      public TdbCompressionContext()
      Constructor, create a new blank context.
  • Method Details

    • isStarted

      public boolean isStarted()
      Check whether the compression operation has been started on the server
      Returns:
      true if the operation has started
    • isComplete

      public boolean isComplete()
      Check whether the compression operation has completed on the server
      Returns:
      true if the operation has completed
    • hasUnindexedRecords

      public boolean hasUnindexedRecords()
      Check if the database to be compressed contains modified unindexed records. This property is only valid after the first call to the Compress method on the TdbDatabaseDesign class.
      Returns:
      true if the database contains modified unindexed records.
    • getNewName

      public String getNewName()
      Retrieve the new filename of the database's BAF.
      Returns:
      The name of the BAF that will contain the compressed form of the database contents.
    • setNewName

      public void setNewName(String filename)
      Set the new filename of the database's BAF. This file will contain the result of the compression operation, the original BAF is unaffected.
      Parameters:
      filename - The name of the new file.
    • getMaxRecs

      public int getMaxRecs()
      Retrieve the total number of records to be compressed. This property is only valid after the first call to the Compress method on the TdbDatabaseDesign class.
      Returns:
      Total number of records to be compressed.
    • getProgress

      public int getProgress()
      Retrieve the progress made to date by the compression operation. This property assumes that the compression is operating iteratively, and has no meaning if the operation is being performed all at once.
      Returns:
      NUmber of records compressed to date.
    • getKeepRecordIds

      public boolean getKeepRecordIds()
      Check whether the compression operation is maintaining record IDs.
      Returns:
      true if record IDs are being maintained during the operation.
    • setKeepRecordIds

      public void setKeepRecordIds(boolean keep)
      Establish whether to maintain record IDs during compression. If this is set false, the database will require reindexing following compression.
      Parameters:
      keep - Flag determining whether to keep record IDs during compression.