{
{ PURPOSE:
{   These types are used to define a SUBPRODUCT INFORMATION FILE.
{
{      RAT$SUBPRODUCT_INFO_HEADER record contains the following fields:
{
{        ATTRIBUTES_P  - Relative pointer to the record containing
{                     subproduct attributes.
{
{                     Defined by DEFINE_SUBPRODUCT.
{
{                     Used by INSS.
{
{        ELEMENT_LIST_P  - Relative pointer to the first element that makes
{                     up the element list.
{
{                     Defined by DEFINE_SUBPRODUCT.
{
{                     Used by INSS.
{
{
{        PATH_CONTAINER_LENGTH  - The length of the path container.
{
{                     Defined by QUIT for DEFINE_SUBPRODUCT utility.
{
{                     Used by INSS.
{
{        PATH_CONTAINER_P  - Relative pointer to an array containing the
{                     names that form paths critical to installation.  The
{                     path container contains the installation catalog path,
{                     and optionally defined installer procedure path and/or
{                     library merge paths.
{
{                     Defined by QUIT for DEFINE_SUBPRODUCT utility.
{
{                     Used by INSS.
{
{        PSRS_ANSWERED_COUNT  - The number of PSR answered by this
{                     correction (if this does represent a correction to a
{                     subproduct).  This is not a required field.
{
{                     Defined by DEFINE_PSRS_ANSWERED.
{
{                     Used by INSS.
{
{        PSRS_ANSWERED_P  - Relative pointer to an array containing
{                     names of PSRs answered by this correction.  This is
{                     not a required field.
{
{                     Defined by user with DEFINE_PSRS_ANSWERED.
{
{                     Used by INSS.
{
{
{   The RAT$SUBPRODUCT_ATTRIBUTES record contains the following fields:
{
{
{        ADDITIONAL_PRODUCTS  - List of names of other licensed products
{                     this subproduct can be associated with.  This list is
{                     in addition to the LICENSED_PRODUCT field.  This is a
{                     31 character field.
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Used by SMD and INSS.
{
{        AUTO_INSTALL  - Boolean value that when set to true indicates that
{                     this subproduct is automatically installed without
{                     directly naming the subproduct.  If false the
{                     subproduct can only be installed by specifying the
{                     subproduct by name.
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Used by INSS.
{
{
{        CALCULATE_CONTENTS_CHECKSUM - Boolean value that indicates if the
{                     contents checksum should be calculated.
{
{
{        CATALOG_PERMIT  - A record defining the public access and share
{                     modes and application information allowed for the
{                     contents of the installation catalog.  Permits are not
{                     required to be defined.  If none given, none will be
{                     created.
{
{                     Defined by user with DEFINE_CATALOG_PERMITS.
{
{                     Used by INSS.
{
{        CORRECTION_BASE_LEVEL  - The subproduct level used as the base to
{                     apply against when this subproduct record represents a
{                     correction.  This is in the same format as the
{                     subproduct LEVEL field.  This field is ignored when
{                     the SUBPRODUCT_TYPE is release.
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Used by INSS.
{
{        CORRECTION_BASE_SIF_IDENTIFIER  - The sif identifier from the base PACS
{                     catalog.  This should only be set when this PACS catalog
{                     was created by CREATE SUBPRODUCT CORRECTION.
{
{                     Copied from the base level PACS catalog during CREATE SUBPRODUCT CORRECTION.
{
{                     Used by CREATE SUBPRODUCT CORRECTION.
{
{        (subproduct_)DATE_LEVEL  - A julian date that indicates the
{                     subproduct's time line relationship between this level
{                     and other levels of this subproduct.
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Used by INSS.
{
{        (subproduct_)DEPENDENCIES  -  List of names of licensed products
{                     and/or subproducts this subproduct is dependent upon
{                     in regrades to installation.
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Used by INSS.
{
{        (subproduct_)NAME  - Name of the subproduct.  This is a 31
{                     character name field.
{
{                     Defined by user with DEFINE_SUBPRODUCT.
{
{                     Used by SMD and INSS.
{
{        DESCRIPTION  - A string value description of the subproduct.
{                     If the subproduct is defined as the primary subproduct
{                     of a licensed product this description applies for the
{                     licensed product as well.
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Used by INSS and PACS display commands.
{
{        DEVELOPMENT_GROUP  - The name of the group responsible for the
{                     subproducts development.
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Use by (unknown).
{
{                     Used by PACS.
{
{        FIRST_LEVEL_ELEMENT_COUNT  - Number of elements that are contained
{                     directly under the installation catalog.  An element
{                     can either be a catalog or a file.
{
{                     Defined by DEFINE_SUBPRODUCT.
{
{                     Used by PACS and INSS.
{
{        FILES_STAMPED  - Boolean that signifies if the user information
{                     (UI) field of the subproduct's files has been used to
{                     identify the files.  The value stored in the UI is the
{                     contents of the subproduct LEVEL field.
{
{                     All the files in the PACS catalog will automatically
{                     be stamped when the STAMP_FILES parameter is
{                     specified TRUE on the DEFINE_SUBPRODUCT_ATTRIBUTES
{                     subcommand.
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{                     All the files in the PACS catalog will automatically
{                     be stamped stam when the STAMP_FILES parameter is
{                     specified TRUE on the DEFINE_SUBPRODUCT_ATTRIBUTES
{                     subcommand.
{
{                     Used by INSS.
{
{        HIDDEN(_subproduct)  - Boolean value that when set to true will
{                     cause the subproduct to not be processed in any way
{                     unless the subproduct is named directly.
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Used by INSS.
{
{        INSTALLATION_SCHEME  - Describes the installation scheme used for
{                     the subproduct type (rac$release or rac$correction)
{                     as either rac$cycle_based, rac$catalog_based or
{                     rac$version_based.  This field is important for
{                     managing the active directory.
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Used by INSS.
{
{        INSTALLATION_PATH  - A record containing the index and length into
{                     the path container for the subproduct's installation
{                     path.  The installation path defines the catalog that
{                     is the lowest level subcatalog that still contains all
{                     of the subproduct's files and subcatalogs as defined
{                     by the element list.  The first 2 names in the
{                     container are the master catalog which may be user
{                     definable (see INSTALLATION_PATH_OPTION).
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Used by INSS.
{
{        INSTALLATION_PATH_OPTION  - Contains the option given (or required
{                     of) the user regarding the subproduct's
{                     INSTALLATION_PATH.   The user may be allowed (or
{                     required) to define the master catalog, define the
{                     family name or define the user name.
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Used by INSS.
{
{        INSTALLER_PROCEDURE  - A record containing the index and length
{                     into the path container for the path to the
{                     subproduct's installation procedure.  The path
{                     contains only that part of the path that is not the
{                     same as the INSTALLATION_PATH (it is appended
{                     to the installation path at time of
{                     execution).  The path will also include the command
{                     procedure name or program descriptor).  If an
{                     INSTALLER_PROCEDURE is not defined the values will be
{                     set to 0.
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Used by INSS.
{
{        (subproduct_)INTERNAL_LEVEL  - An NOS/VE level representation used
{                     internally by NOS/VE development.  This is hidden from
{                     displays unless asked for directly.
{
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Used by NOS/VE development.
{
{        (subproduct_)LEVEL  - The subproduct level in the notation given by
{                     the developing group.  This is a 31 character name.
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Used by SMD and INSS.
{
{        LICENSED_PRODUCT  - Name of the licensed product that this
{                     subproduct belongs to.
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Used by SMD and INSS.
{
{         (subproduct)NAME  - A string containing the name of the subproduct.
{
{                     Defined by user with DEFINE_SUBPRODUCT.
{
{                     Used by INSS.
{
{        PACS_CATALOG_PATH  - A record containing the path to the PACS catalog
{                     and the length of the path.
{
{                     Defined by user with DEFINE_SUBPRODUCT.
{
{                     Used by INSS.
{
{        PRIMARY(_subproduct)  - Boolean value defining the subproduct as
{                     the representative for the licensed product.  (Used for
{                     displaying the level of the licensed product.)
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Used by INSS.
{
{        PRODUCT_FILE_SIZE  - The total file space used by files that
{                     are of storage class type PRODUCT.
{
{                     Calculated by DEFINE_SUBPRODUCT and DEFINE_STORAGE_CLASS.
{
{                     Used by PACS and INSS.
{
{        SERVICE_CRITICAL_FILE_SIZE  - The total file space used by files that
{                     are of storage class type SERVICE CRITICAL.
{
{                     Calculated by DEFINE_SUBPRODUCT and DEFINE_STORAGE_CLASS.
{
{                     Used by PACS and INSS.
{
{        SIF_IDENTIFIER - A unique name that is assigned to each
{                     SUBPRODUCT INFORMATION FILE.
{
{        (subproduct_)SIZE  - Disk space in bytes required to load the
{                     subproduct.  This is the size of the backup file of
{                     the PACS catalog.  This is required for building the
{                     release materials.
{
{                     Calculated by DEFINE_SUBPRODUCT.
{
{                     Used by PACS and INSS.
{
{        SUBPRODUCT_ELEMENT_COUNT - Total number of files and catalogs in the element list.
{
{                     Calculated by DEFINE_SUBPRODUCT.
{
{                     Used by CRESC.
{
{
{        SUBPRODUCT_PRIORITY  - Defines the subproduct's relative importance
{                     to the installation process.  If a file is needed early
{                     in the installation process to load other products it
{                     should be given a high priority.
{
{                     Defined by user with DEFINE_SUBPRODUCT_ATTRIBUTES.
{
{                     Used by SMD and INSS.
{
{        SUBPRODUCT_TYPE  - Defines the subproduct's type as being a
{                     rac$release, rac$correction.
{
{                     Defined by user with DEFINE_SUBPRODUCT.
{
{                     Used by SMD and INSS.
{
{        UNUSED  - Space available for future fields as needed.  This is
{                     described in bytes.
{
{
{      RAT$ELEMENT record is a variant record containing the following
{      fields:
{
{
{        (element_)NAME  - The name of the element the record is defined
{                     for.
{
{                     Defined by DEFINE_SUBPRODUCT.
{
{                     Used by PACS and INSS.
{
{        PERMIT  - Record defining the public access and share modes
{                     and any application information allowed.
{
{                     Defined by user with either DEFINE_CATALOG_PERMITS or
{                     DEFINE_FILE_PERMITS depending on element type.
{
{                     Used by INSS.
{
{        ACTIVE_ELEMENT - Boolean indicating if the element represents
{                     an actual catalog or file in the PACS catalog. If the
{                     element is not active, then there is no corresponding file
{                     or catalog in the PACS catalog.  Currently, only
{                     subproduct corrections using a version based installation
{                     contain active elements.  Inactive elements are not
{                     staged/activated by INSTALL_SOFTWARE.
{
{                     Set to TRUE (always) by CREATE_ELEMENT_LIST.  Set FALSE
{                     if appropriate by GENERATE_CORRECTION.  Manipulated by
{                     VALIDATE_FOR_CORRECTION of INSTALL_SOFTWARE.
{
{                     Used by PACS and INSS.
{
{        NEXT_ELEMENT_ACROSS_P  - Relative pointer to the next
{                     element at the current catalog level.
{
{                     Defined by DEFINE_SUBPRODUCT.
{
{                     Used by PACS and INSS.
{
{        ELEMENT_TYPE  - The element's type as either rac$catalog or
{                     rac$file.
{
{                     Defined by DEFINE_SUBPRODUCT.
{
{                     Used by PACS and INSS.
{
{
{        The following fields are available when the element type is
{        rac$catalog:
{
{
{        ELEMENT_COUNT  - Number of elements contained in the
{                     catalog.
{
{                     Defined by DEFINE_SUBPRODUCT.
{
{                     Used by PACS and INSS.
{
{
{        FIRST_ELEMENT_DOWN_P  - Relative pointer to the first element under
{                     the catalog defined by the element record.
{
{                     Defined by DEFINE_SUBPRODUCT.
{
{                     Used by PACS and INSS.
{
{        The following fields are available when the element type is
{        RAC$FILE:
{
{
{        (file_)CONTENTS_CHECKSUM  - Checksum of the contents of this subproduct file.
{
{                     Defined by DEFINE_SUBPRODUCT.
{
{                     Used by PACS and INSS.
{
{        (file_)CORRECTION_BASE_CONTENTS_CKSUM  - Checksum of the contents of the
{                     base file for this correction.  Copied by CREATE SUBPRODUCT CORRECTION
{                     from the base level subproduct information file to the new
{                     subproduct information file.
{
{                     Used by CREATE SUBPRODUCT CORRECTION.
{
{        (file_)ATTRIBUTES_CHECKSUM  - Checksum of the attributes of this subproduct file.
{
{                     Defined by DEFINE_SUBPRODUCT.
{
{                     Used by PACS and INSS.
{
{        (file_)PRE_GENC_CONTENTS_CHECKSUM  - Checksum of the contents of this subproduct file
{                     before GENERATE CORRECTION was used to create a correction file for this
{                     subproduct.
{
{                     Defined by DEFINE_SUBPRODUCT and moved to this location by GENERATE CORRECTION.
{
{                     Used by CRESC and INSS.
{
{        (file_)SIZE  - Size of the file (in bytes).  Used in building
{                     release materials.
{
{                     Defined by DEFINE_SUBPRODUCT.
{
{                     Used by PACS and INSS.
{
{        STORAGE_CLASS  - Storage class to which the file will be installed
{                     when activated.
{
{                     Defined by user with DEFINE_STORAGE_CLASS.
{
{                     Used by INSS.
{
{        RING_ATTRIBUTES  - Ring attributes to which the files will be set
{                     when the file is stagged.
{
{                     Defined by user with DEFINE_RING_ATTRIBUTES.
{
{                     Used by INSS.
{
{        CORRECTION_DIRECTIVES - A set which is used to direct correcting
{                     this element.
{
{                     Set to the empty set by CREATE_ELEMENT_LIST.
{                     Updated in VALIDATE_FOR_CORRECTION of INSTALL_SOFTWARE.
{
{                     Used by INSS.
{
{        CORRECTION_FORMAT  - File format for applying the correction if
{                     file represents a correction.  The formats are rac$corr_format_not_defined
{                     rac$object_library, rac$source_library or
{                     rac$replacement.  This is only required for subproduct's
{                     with SUBPRODUCT_TYPE defined as rac$correction.
{
{                     Defined by CREATE_ELEMENT_LIST.
{                     May be redefined by user with DEFINE_CORRECTION_FORMAT.
{
{                     Used by INSS.
{
{        FILE_CONTENTS_AND_STRUCTURE - The file contents and structure of a
{                     file.  The formats are rac$object, rac$source_library
{                     and rac$replacement.  Rac$replacement is used if neither
{                     rac$object_library or rac$source_library is correct.
{
{                     Defined in CREATE_ELEMENT_LIST.
{
{                     Used by DEFINE_CORRECTION_FORMAT.
{
{        LIBRARY_MERGE  - A record containing the index and length into the
{                     path container for the path to the library that the
{                     file will be merged with (if a library merge is
{                     required).  If a LIBRARY_MERGE is not defined the
{                     values will be set to 0.
{
{                     Defined by user with DEFINE_LIBRARY_MERGE.
{
{                     Used by INSS.
{

  CONST
    rac$max_additional_products = 5,
    rac$max_dependencies = 5,
    rac$max_path_container_length = 0ffffffff(16),
    rac$max_psr_count = 1000,
    rac$psr_name_length = 7;

  TYPE
    rat$additional_products = array [1 .. rac$max_additional_products] of
          ost$name;

  TYPE
    rat$checksum = integer;

  TYPE
    rat$correction_directive_types = (rac$use_base_level_catalog,
          rac$use_correction_base_catalog, rac$use_previous_correction,
          rac$use_release_file, rac$use_replacement_file);

  TYPE
    rat$correction_directives = set of rat$correction_directive_types;

  TYPE
    rat$correction_format = (rac$object_library, rac$source_library,
          rac$replacement);
  TYPE
    rat$psr = string (rac$psr_name_length);

  TYPE
    rat$psrs_answered_count = 0 .. rac$max_psr_count;

  TYPE
    rat$psrs_answered = array [ * ] of rat$psr;

  TYPE
    rat$psrs_answered_p = REL (rat$subproduct_info_sequence)
          ^rat$psrs_answered;

  TYPE
    rat$development_group = string (31);

  TYPE
    rat$element = record
      name: ost$name,
      permit: rat$permit,
      active_element: boolean,
      next_element_across_p: rat$element_p,
      case element_type: rat$element_type of
      = rac$catalog =
        element_count: rat$element_count,
        first_element_down_p: rat$element_p,
      = rac$file =
        attributes_checksum: rat$checksum,
        contents_checksum: rat$checksum,
        correction_base_contents_cksum: rat$checksum,
        correction_directives: rat$correction_directives,
        correction_format: rat$correction_format,
        file_contents_and_structure: rat$correction_format,
        library_merge: rat$path_container_indexer,
        modification_date_time: ost$date_time,
        pre_genc_contents_checksum: rat$checksum,
        ring_attributes: rat$ring_attributes,
        size: amt$file_length,
        storage_class: rmt$mass_storage_class,
      casend,
    recend;

  TYPE
    rat$element_count = integer;

  TYPE
    rat$element_list_p = REL (rat$subproduct_info_sequence)
          ^rat$element;

  TYPE
    rat$element_p = REL (rat$subproduct_info_sequence) ^rat$element;

  TYPE
    rat$element_type = (rac$catalog, rac$file);

  TYPE
    rat$installation_path_option = (rac$not_definable,
          rac$definable_master_catalog, rac$definable_family_name,
          rac$definable_user_name);

  TYPE
    rat$installation_scheme = (rac$cycle_based, rac$catalog_based,
          rac$version_based);

  TYPE
    rat$path_container = array [ * ] of ost$name;

  TYPE
    rat$path_container_index = 0 .. rac$max_path_container_length;

  TYPE
    rat$path_container_indexer = record
      path_container_index: rat$path_container_index,
      path_length: rat$path_container_length,
    recend;

  TYPE
    rat$path_container_length = 0 .. rac$max_path_container_length;

  TYPE
    rat$path_container_p = REL (rat$subproduct_info_sequence)
          ^rat$path_container;

  TYPE
    rat$permit = record
      defined: boolean,
      permit_selections: pft$permit_selections,
      share_requirements: pft$share_requirements,
      application_info: pft$application_info,
    recend;

  TYPE
    rat$ring_attributes = record
      r1: ost$ring,
      r2: ost$ring,
      r3: ost$ring,
    recend;

  TYPE
    rat$subproduct_attributes = record
      additional_products: rat$additional_products,
      auto_install: boolean,
      calculate_contents_checksum: boolean,
      catalog_permit: rat$permit,
      correction_base_level: rat$subproduct_level,
      correction_base_sif_identifier: rat$sif_identifier,
      date_level: rat$subproduct_date_level,
      dependencies: rat$subproduct_dependencies,
      description: rat$subproduct_description,
      development_group: rat$development_group,
      first_level_element_count: rat$element_count,
      files_stamped: boolean,
      hidden: boolean,
      installation_scheme: rat$installation_scheme,
      installation_path: rat$path_container_indexer,
      installation_path_option: rat$installation_path_option,
      installer_procedure: rat$path_container_indexer,
      internal_level: rat$subproduct_internal_level,
      level: rat$subproduct_level,
      licensed_product: rat$licensed_product,
      name: rat$subproduct_name,
      pacs_catalog_path: rat$path,
      primary: rat$primary_subproduct,
      product_file_size: rat$subproduct_size,
      service_critical_file_size: rat$subproduct_size,
      sif_identifier: rat$sif_identifier,
      size: rat$subproduct_size,
      subproduct_element_count: rat$subproduct_element_count,
      subproduct_priority: rat$subproduct_priority,
      subproduct_type: rat$subproduct_type,
      user_permanent_file_size: rat$subproduct_size,
      unused: array [1 .. 47] of cell,
    recend;

  TYPE
    rat$subproduct_attributes_p = REL (rat$subproduct_info_sequence)
          ^rat$subproduct_attributes;

  TYPE
    rat$subproduct_date_level = string (7);

  TYPE
    rat$subproduct_dependencies = array [1 .. rac$max_dependencies] of
          ost$name;

  TYPE
    rat$subproduct_element_count = integer;

  TYPE
    rat$subproduct_info_header = record
      attributes_p: rat$subproduct_attributes_p,
      element_list_p: rat$element_list_p,
      path_container_length: rat$path_container_length,
      path_container_p: rat$path_container_p,
      psrs_answered_count: rat$psrs_answered_count,
      psrs_answered_p: rat$psrs_answered_p,
    recend;

  TYPE
    rat$subproduct_info_sequence = SEQ ( * );

  TYPE
    rat$subproduct_size = amt$file_length;

  TYPE
    rat$subproduct_priority = (rac$low, rac$medium, rac$high,
          rac$installation_tools, rac$packing_list);


*copyc fsc$max_path_size
*copyc amt$file_length
*copyc amt$ring_attributes
*copyc ost$date_time
*copyc ost$name
*copyc pft$application_info
*copyc pft$permit_selections
*copyc pft$share_requirements
*copyc rat$licensed_product
*copyc rat$path
*copyc rat$primary_subproduct
*copyc rat$sif_identifier
*copyc rat$subproduct_description
*copyc rat$subproduct_internal_level
*copyc rat$subproduct_level
*copyc rat$subproduct_name
*copyc rat$subproduct_type
*copyc rmt$mass_storage_class
