4. Syntax: Introduction
This section begins with an introduction to the concepts and elements that constitute the syntax for messages. The second section presents an overview of the encoding scheme. The third section describes in detail the elements of the message syntax.
4.1 Introduction
This specification defines syntactic requirements for messages when they are passed from one CBMS to another. The specification is designed to meet the following goals.
-
Provide a concise flexible representation scheme.
-
Simplify message parsing.
-
Support non-textual components in messages (for example, facsimile, graphics, or speech (3)).
(3) While this message format specification is not intended to be used as a basis for the intnge of all facsimile information, it does recognize that CBMS messages may contain facsimile components.
4.1.1 Message structure
Messages have two classes of components, fields and messages. A field corresponds to one of the semantic components defined in this message format specification. A message is simply another message.
The type of a field in a message determines both its meaning and the form for its contents. (See Section 4.3.2.)
Fields in a message are composed of syntactic elements called data elements. A Message data element is used to represent messages; a Field data element is used to represent fields. (The term "field" is simply a semantic construct, distinct from "Field Data Element", which is a syntactic construct.) Many of the fields defined in this message format specification estricted to containing only one kind of data element. (See Section 4.3.2.)
Each field defined in this message format specification has been assigned a unique numeric identifier that is used in conjunction with the Field data element. Separate identifiers are provided for vendor-defined fields and for extending the identifier encoding space. A list of fields and identifiers appears in Section 4.3.2 and in Appendix C.
Throughout the message format specification, fields are referred to by label name rather than by their numeric identifiers. Field labels are names like "Sender", "Warning-Date", or "Circulate-To". The field labels chosen for the specification are names that are in common use in current CBMSs. The specification does not require a CBMS to use these field labels in displaying fields to the user, although such usage is encouraged to provide a common user interface.
4.1.2 Data elements
For the purpose of determining compliance with the syntax defined in this specification, data elements are divided into two groups, basic and optional.
-
BASIC: All message receiving systems must process these syntactic elements, interpreting their values according to the message format specification.
-
OPTIONAL: Message receiving systems need not process these syntactic elements in order to be in compliance.
In addition, complying CBMSs must meet requirements regarding their ability to process the components found inside data elements. These requirements are discussed in Section 4.2.2. (Semantic compliance is defined in Section 3.1.2.)
This message format specification classifies data element types as either primitives or constructors. (See Sections 4.1.2.1 and 4.1.2.2.) Primitive data elements, such as ASCII-String, are basic building blocks. Constructor data elements, such as Message or Sequence, contain one or more primitive or constructor data elements. Some constructors, such as Sequence, may be composed of any other data element. Some, such as Message, may contain only certain data elements. (See Section 4.3.1.)
4.1.2.1 Primitive data elements
A primitive data element contains a basic item of information; it is not composed of other data elements. In current CBMSs, the most commonly used primitive data element is ASCII-String, a series of ASCII characters. Other primitive data elements are Integer, 2's complement integers; Bit-String, a series of bits; and Boolean, either True or False.
One primitive data element, End-Of-Constructor, is used only as a structural element within constructor data elements and has no meaning by itself. End-of-Constructor is used to provide an end marker for constructor data elements that do not have an explicit length. (See Section 4.2.2.1.) Any other use is not valid syntactically.
4.1.2.2 Constructor data elements
The Data Element Contents of constructor data elements contain one or more data elements. The most general form of a constructor is a Sequence or a Set, since both Sequences and Sets may contain any data element. Other constructors are specialized forms of sequences.
A Message data element is a constructor. It may contain only Field data elements, other Message data elements, or encrypted or data compressed forms of these elements. A Field data element can contain any data element. It also indicates which specific field is being represented. The contents of some fields are restricted to a single type of data element, such as ASCII-String or Date.
4.1.3 Properties
Any data element may have associated with it a Property-List, which contains properties such as a Printing-Name (Section 4.1.3.1) or one or more Comments (Section 4.1.3.2). A mechanism to support vendor-defined properties has been supplied by this specification, as well as a mechanism to extend the list of property identifiers.
4.1.3.1 Printing-names
Printing-Names are used to provide labels that can be displayed along with their respective data elements. For example, a message originator may use a Printing-Name property to request that the To field of a message be labeled "Distribution:" when it is printed by its recipients.
4.1.3.2 Comments
The Comment property is used to allow comments to be associated with any data element without affecting its actual contents. For example, someone reviewing the text of a message could add the comment "This looks good" to the Text field without either altering the body itself or adding a separate comment field.
4.1.4 Data compression and encryption
Two constructor data elements, Compressed and Encrypted, have been provided for use by a CBMS that supports data compression or encryption. They may be used to hold the compressed or encrypted contents of any data element, including Messages and Fields, and may occur wherever their compressed or encrypted contents may appear. A mechanism is included to allow the user to identify the encryption or compression algorithm used (Sections 4.3.4 and 4.3.5).
4.1.5 Data sharing
Data sharing is the multiple use of a data element via references to a single copy. It is used in two situations.
-
For economy when a large object appears more than once in a message. Data sharing may be used in this situation to economize on storage and transmission costs.
-
For consistency when the same object appears more than once in a message. If one instance of that object is altered, all instances must reflect this alteration. In this case several copies of the same object will not serve the purpose as well as data sharing.
While there is a demonstrable need for facilities to support data sharing, this specification does not define such a mechanism. At this time there is insufficient experience with data sharing in messages to allow standardization. The specification is sufficiently flexible however to allow extensions to the syntax for supporting data sharing at a later time.