OnixS C++ FIX Engine  4.12.0
API Documentation
EventBasedDecoder Class Reference

#include <OnixS/FIXEngine/FIX/SbeEventBasedDecoder.h>

Public Member Functions

 EventBasedDecoder (const std::string &xmlTemplates, ISbeCustomCoderLibrary *customCoders=ONIXS_FIXENGINE_NULLPTR)
 
 ~EventBasedDecoder ()
 
bool decodeSingleMessage (int version, int templateId, size_t rootBlockLength, const unsigned char *buffer, size_t offset, size_t count, IDecodeListener *listener, size_t *numberOfDecodedBytes) const
 
unsigned schemaVersion () const
 
unsigned schemaId () const
 
std::string schemaSemanticVersion () const
 
std::string schemaHeaderType () const
 

Detailed Description

Definition at line 40 of file SbeEventBasedDecoder.h.

Constructor & Destructor Documentation

EventBasedDecoder ( const std::string &  xmlTemplates,
ISbeCustomCoderLibrary customCoders = ONIXS_FIXENGINE_NULLPTR 
)

Creates the SBE to FIX Decoder.

Parameters
xmlTemplatesXML-based SBE templates.
customCodersThe custom coders library.

Destructor.

Member Function Documentation

bool decodeSingleMessage ( int  version,
int  templateId,
size_t  rootBlockLength,
const unsigned char *  buffer,
size_t  offset,
size_t  count,
IDecodeListener listener,
size_t *  numberOfDecodedBytes 
) const

Tries to decode the given FAST stream buffer into the corresponding FIX Message.

Parameters
[in]templateIdThe identifier of the SBE template, used to decode the input data.
[in]versionThe version of the SBE schema, used to decode the input data.
[in]rootBlockLengthThe length of the root block. This value should be extracted from the message preamble, or from other source.
[in]bufferThe FAST stream chunk to be decoded.
[in]offsetThe index in the buffer at which decoding begins.
[in]countThe number of bytes to analyze during the decoding.
[in]listenerThe listener which receives decoding events.
[out]numberOfDecodedBytesThe number of bytes that contained the encoded FIX Message.
Warning
The message should point to an existing object. This object is not owned by the Decoder and should be managed by the user.
Exceptions
Anexception if the decoding error is detected.
Returns
'true' if the given bytes could be decoded into a FIX message, otherwise - 'false'.
std::string schemaHeaderType ( ) const

The name of the encoding type of the message header, which is the same for all messages in a schema.

unsigned schemaId ( ) const

The schema identifier.

std::string schemaSemanticVersion ( ) const

The semantic version of the SBE schema.

unsigned schemaVersion ( ) const

The maximum known version of the SBE schema.


The documentation for this class was generated from the following file: