Class ModuleHeader

java.lang.Object
binaryFileStorage.ModuleHeader
All Implemented Interfaces:
Serializable, ManagedParameters
Direct Known Subclasses:
ClickBinaryModuleHeader, LtsaModuleHeader, WhistleBinaryModuleHeader

public abstract class ModuleHeader extends Object implements Serializable, ManagedParameters
Class to contain module specific information which will be stored at the end of a binary data file, just before the BinaryFooter.
Author:
Doug Gillespie
See Also:
  • Constructor Details

    • ModuleHeader

      public ModuleHeader(int moduleVersion)
      Parameters:
      moduleVersion -
  • Method Details

    • createHeader

      public abstract boolean createHeader(BinaryObjectData binaryObjectData, BinaryHeader binaryHeader)
      Read data from a byte array to recreate a module header being read back from file.

      The BinaryHeader and ModuleHeader can be used to check version numbers if required.

      Parameters:
      binaryObjectData - data read from file
      binaryHeader - binary Header from data file
      Returns:
      true if unpacked successfully.
    • getModuleVersion

      public int getModuleVersion()
      Returns:
      the moduleVersion