Ada Type Interchange Generator

Automated Message Conversion for Heterogeneous Communication

The main function of the Ada Type-Interchange Generator (ATIG) is to create and maintain interchange subprograms that:

This mechanism (often referred to as marshalling) can be used to transmit data values (messages) between heterogeneous computers running software compiled by different compilation systems, especially computer architectures using different "endian-ness" or different floating-point formats. The message sender can call an interchange subprogram for the message¹s type to write its current value into a byte string. The sender will then transmit the byte string over some communication medium to a receiver that will read its value into a local data structure by calling the corresponding interchange procedure. Agreed-upon formats for predefined type values (that is, integers, reals, and bytes) are used to ensure that the receiver gets a data value identical to that of the sender even if the layout used by each local compiler is different. This mechanism generates pure Ada and is fully portable.

Example:

Example

ATIG subprograms write composite data structures into the byte string one component at a time. The byte representation for each component is constructed by the Write procedure for the component type. Nested structures are thus "flattened" into a sequence of predefined leaf values through a sequence of calls to Write subprograms. The read process is analogous. Byte sequences are convert-ed into values and stored in the components of the local data structure. ATIG attempts to minimize the number of bytes in each type¹s representation, especially for unconstrained types where only useful data is carried into the stream.

Automated generation and consistency checking of interchange subprograms is provided by ATIG for the following kinds of types:

Several transfer formats for the predefined leaf values can be defined to serve diverse purposes:

The user can change formats by substituting a different implementation (body) for the package, pro-viding interchange of the predefined types. Two user commands are defined by ATIG. They can be invoked at the UNIX shell with a command line or via a GUI. These commands provide the capability to:

Both commands will traverse the type hierarchy of any type to ensure that up-to-date interchange subprograms exist for all component types in the closure of the hierarchy.


products

atig technical specification | atig pdf (168K)

ada analyzer | ada repair | ada analyzer/ ada repair training

little tree home | about little tree | technical articles | email