The bulk of the messaging used within the Sybase RAP system
contains market data. Market data messages are buffered within a
message of type RDS_PACKET
.
An RDS_PACKET
is used
as a container for one or more market data messages.
For market data messages, Sybase RAP uses a template to encode (and decode) each message in the proper format. The message format consists of a message header, a fixed-length portion of the message, and a variable-length portion. Each fixed-length field will be packed into the fixed-length portion of the message, according to the offset for the field obtained from the template. Each variable-length field will be appended to the message after the fixed-length portion, preceded by a one-byte length.
The market data message header contains the market data message type and total length. The fixed-length portion of the message appears after the market data header. Each variable-length field will follow, preceded by a single byte which indicates field length.