OnixS C++ FIX Engine  4.10.1
API Documentation
OnixS::FIX::FAST Namespace Reference

Classes

class  Decoder
 
class  Encoder
 
class  EventBasedDecoder
 
class  IDecodeListener
 

Functions

*decoder tryDecode (buffer, offset, count,&message,&numberOfDecodedBytes)
 

Function Documentation

* decoder OnixS::FIX::FAST::tryDecode ( buffer  ,
offset  ,
count  ,
message,
numberOfDecodedBytes 
)

Characteristics of the input data stream for decoding.

This enumeration allows to setup decoder in dependent-decoding (i.e. decodeEachMessageIndependently == false) mode for particular characteristics of the input data stream.

The CompleteMessagesOnly allows to perform decoding faster, but requires explicit call of Decoder::reset when someone error occurs or Decoder::decode returns NULL. Decoder::decode() will fire exception if such reset was omitted after exception.

This commonly prohibits usage of the mode for decoding streaming data like TCP/IP stream. On another hand the mode is highly recommended for the data distributed via UDP multicast or other packet transport which requires reset of decoder at someone strongly determined points.

The CouldContainPartialMessages initiates a bit slower decoding then the CompleteMessagesOnly but could be used for stream data decoding using following method:

Decoder decoder(templates, dictionary, false, InputDataTraits::CouldContainPartialMessages); ... const Message message = 0; while(!message) { / consume some data