Chapter 3

3 - LOGICAL RECORD SYNTAX

3.1 Record Format Categories

From a syntactical point of view, we can speak of two different DLIS Logical Record structures for storing information -- namely:

3.2 Explicitly Formatted Logical Record (EFLR)

An EFLR has a variable-length Logical Record Body (LRB). The format of the LRB is derived from an analysis of the record itself. An EFLR is defined in such a general way that it can be used to contain a wide variety of information related to logging data.

The syntax of an EFLR permits the system or the application program that is reading DLIS to interpret unambiguously the information that is contained in the EFLR. The Logical Record Type in the Logical Record Segment Header permits quick scanning of Logical Records to locate certain key types of information. The structures within the EFLR can then be interpreted hierarchically to get detailed attributes of the information.
3.2.1 EFLR: General Layout
Each EFLR encapsulates a table of information. The rows of the table represent Objects, and the columns of the table represent Attributes of the Objects. At the beginning of the table there is a Template that defines the columns. The table can be viewed in another way as a Set of Objects, all of the same Type, defined by the Template of the Set. Figure 3-1 illustrates a typical EFLR.


Figure 3-1. Illustration of EFLR Structure

Each EFLR contains one and only one Set. A Set is interposed between the EFLR and the Objects in the Set to provide a structure that can be named, that represents a specific collection of Objects of a given subtype of the EFLR's Type, and that can be accessed with the same syntactical machinery that is used to access Objects. Although an EFLR may contain only one Set, that Set may be one of several different types implied by the Logical Record Type of the EFLR.

Formally, a Set consists of one or more Objects of the same type, preceded by a Template. Each Object has one or more Attributes. Sets, Objects and Attributes have certain Characteristics which serve to distinguish one from another. Templates do not have intrinsic Characteristics. Rather, Templates are used to specify the presence, order, and default Characteristics of the Attributes of the Objects in the Set. This permits the number of explicitly present Characteristics of Attributes in the Object rows to be reduced -- to zero in some cases.

3.2.2 EFLR: Component Structure
The basic syntactic unit of an EFLR is the Component. Components are used for structural purposes and to carry information describing the entities, i.e., Set, Objects, and Attributes, that make up an EFLR.

The following notational conventions are used in describing Components:

3.2.2.1 Component Descriptor
The first byte of every Component is its Descriptor. A Descriptor has two parts:
  1. The Component Role. The Role indicates what type of entity is described by the Component.
  2. The Component Format as defined in Figures 3-3, 3-4, and 3-5.
It is possible for a Component to consist entirely of its Descriptor, in which case all Characteristics assume default values.

Bits 1-3 Role Type of Component
000 ABSATR Absent Attribute
001 ATTRIB Attribute
010 INVATR Invariant Attribute
011 OBJECT Object
100 reserved -
101 RDSET Redundant Set
110 RSET Replacement Set
111 SET Set
Figure 3-2. Definition of Component Role


Figure 3-3. Definition of Characteristics and Component Format for Set, Redundant Set, and Replacement Set Components

Comments:


Figure 3-4. Definition of Characteristics and Component Format for Object Components

Comments:


Figure 3-5. Definition of Characteristics and Component Format for Attribute and Invariant Attribute Components

Comments:

3.2.2.2 Component Usage
This paragraph defines the usage of Components. Illustrations of how Components can be combined to form a Set are provided in later sections.

A Set Component defines the beginning of a Set and must be the first Component in the EFLR. The Set Component contains the Set Type, which is not optional and must not be null, and the Set Name, which is optional.

A Set consists of one or more Objects, preceded by a Template. The Objects in a Set share a common set of Attributes. The order and default Characteristics for these Attributes are defined in the Template. The Template immediately follows the Set Component and is terminated by an Object Component. A Template consists of a collection of Attribute Components and/or Invariant Attribute Components, mixed in any fashion. These Components define the structure of the Objects in the Set.

An Object Component defines the beginning of a new Object. The Object Component contains the Object Name, which is mandatory. Following the Object Component are a sequence of Attribute Components and possibly some Absent Attribute Components. An Object's Attribute Components are terminated by the end of the Logical Record or by the occurrence of another Object Component.

All Components in the Template must have distinct, non-null Labels. Attribute Components in the Template specify local default Characteristics for all Objects in the Set. Characteristics not present in Template Attribute Components assume the global default values defined in Figure 3-5. Invariant Attribute Components, which may only appear in the Template, represent Invariant Attributes, i.e., Attributes that are invariant in all Characteristics for all Objects in the Set. Therefore, Attribute Components corresponding to these Invariant Attributes need not and must not appear after Object Components.

All Attributes in the same "column" of a Set must have the same Attribute Label, namely, the one specified in the Template Attribute Component. Therefore, Attribute Components that follow Object Components must not have Attribute Labels. The remaining Characteristics may be freely specified by an Object's Attribute Components. Any Characteristic not present assumes the local default value as specified in the corresponding Attribute Component in the Template.

Missing Attribute Components imply that local defaults should be used for the Characteristics of the corresponding Attribute. Since Attribute order is important within a Set, only trailing Attribute Components can be omitted.

An Attribute is considered to be Absent for an Object when its Attribute Component is replaced by an Absent Attribute Component. An Absent Attribute is one for which no information is provided, not even default meaning.

A Redundant Set is an identical copy of some Set written previously in the same Logical File, including the Set Name and Type. If a Redundant Set is has a null Name, then the Set of which it is a copy must be the only Set in the same Logical File of the same Type, excluding other Redundant Sets, preceding the given Redundant Set.

A Replacement Set has the same Type and (non-null) Name, the same Template, and the same Objects (none added, none deleted) in the same order as a Set written previously in the same Logical File. However, the Attributes of the Replacement Set reflect all updates that may have been applied since the original Set was written. A Replacement Set can be written anywhere in a Logical File following the original Set that it replaces. There may be any number of Replacement Sets for a given original Set.

3.2.3 EFLR: Examples
Two views are used to illustrate EFLRs: symbolic and syntactic. In a symbolic illustration, the EFLR is represented by a Logical Record Segment Header symbol followed by a stream of Component symbols followed by a Logical Record Segment Trailer symbol. The symbols used in these illustrations are defined in Figure 3-6.


Figure 3-6. Symbolic Representation of Components

A syntactic illustration shows Component details, including explicit Characteristics and their values. The Component Descriptor is represented in the form R:F, where R is the Role, defined in Figure 3-2, and F is the concatenation of those symbols, defined in Figures 3-3 through 3-5, specifying which Format bits are set.

3.2.3.1 Symbolic Illustration of an EFLR
Figure 3-7 illustrates an EFLR, segmented into three Logical Record Segments. The segmentation is purely arbitrary and is done this way for illustrative purposes. Although the illustration shows segmentation on Component and Object boundaries, for example, this is not a requirement. Logical Record Segmentation may occur at any byte. The Order in which the Components are illustrated is from left to right, then top to bottom.

There are seven Attributes specified in the Template. One of these is an Invariant Attribute, so the column underneath it is left blank to indicate that no corresponding Attribute Components appear following the Object Components. The row for Object 3 contains an Absent Attribute Component, which means that the third Object has only six Attributes. For the second Object, on the other hand, the last three Attribute Components have been left out. This Object still has seven Attributes, but the last three are identical to the defaults defined in the Template.


Figure 3-7. Symbolic Illustration of an EFLR

3.2.3.2 Syntactic Illustration of an EFLR
Figure 3-8 is a syntactic illustration of an EFLR. It illustrates a Set that spans three Logical Record Segments. This is a Set of Channel Objects (see Chapter 5). Detailed explanation of the entries in the figure is given in the comments that follow. To make the comments less awkward and more illustrative, some allusions are made to the semantic meanings of the Attributes shown in the example and of other entities. These comments are not intended to define any semantic meaning, since that is done in later chapters.

Also note that Attributes in the illustration appear in a different order from that used in Chapter 5 to define Channel Objects and not all Attributes are used. This emphasizes the fact that the order in which Attributes appear in the Template is arbitrary.


Figure 3-8. Syntactic Illustration of an EFLR


Figure 3-8 (cont). Syntactic Illustration of an EFLR


Figure 3-8 (cont). Syntactic Illustration of an EFLR

Comments:

3.3 Indirectly Formatted Logical Record

The format of the Logical Record Body of an Indirectly Formatted Logical Record cannot be interpreted from an analysis of the record itself. Instead, it is defined by the contents of associated EFLRs. Typically, a stream of data is encapsulated in a sequence of IFLRs. There can be several multiplexed sequences of IFLRs in a single Logical File. A referencing mechanism is used to sort them out. This characteristic is particularly useful for recording log data, which is acquired as a sequence of identically-formatted packets, the number of which is unknown by the system when acquisition begins.
3.3.1 IFLR: Specific Structure
Figure 3-9 defines the structure of the Logical Record Body of an Indirectly Formatted Logical Record.


Figure 3-9. Structure of an Indirectly Formatted Logical Record

Comments: