B2BITS FIX Antenna HFT  1.0.13
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
Engine::FIXMessageEx Class Reference

The part of the FIX message storing persistent data and helpers. More...

#include <FIXMessageEx.h>

+ Inheritance diagram for Engine::FIXMessageEx:
+ Collaboration diagram for Engine::FIXMessageEx:

Public Member Functions

 FIXMessageEx ()
 The constructor. More...
 
System::u64 generateNewGlobalId ()
 Generates the new globalMsgID for the message. More...
 
void generateNewGlobalIdBeforeSend ()
 Generates a new globalMsgID for the message before message is sent. More...
 
const PersistentDatagetPersistentData () const
 Returns the persistent data from the message. More...
 
PersistentDatagetPersistentData ()
 Returns the persistent data from the message. More...
 
const PersistentUserDatagetPersistentUserData () const
 Returns the user part of the persistent data from the message. More...
 
PersistentUserDatagetPersistentUserData ()
 Returns the user part of the persistent data from the message. More...
 
System::u64 getTimestamp ()
 Returns the sending/receiving timestamp. More...
 
void * getUserData () const
 Returns user data attached to the message instance. More...
 
bool needNewGlobIDBeforeSend ()
 Returns true if the message is configured to generate a new globalMsgID for the message before the message is sent. More...
 
void setNeedNewGlobIDBeforeSend (bool enable)
 Configures the message to generate a new globalMsgID for the message before the message is sent or to skip the generation. More...
 
const void setPersistentData (const PersistentData &persistentData)
 Sets the persistent data to the message. More...
 
void setPersistentUserData (const PersistentUserData &userData)
 Sets the user part of the persistent data to the message. More...
 
void setTimestamp (System::u64 timestampUsec)
 Sets the sending/receiving timestamp. More...
 
void setUserData (void *userData)
 Attaches the user data to the message instance. More...
 

Static Public Member Functions

static System::u64 getCurrGlobalMsgId ()
 Returns the last generated GlobalMsgId. More...
 
static void seedGlobalMsgId (System::u64 globalMsgId)
 Initializes the global GlobalMsgId generator with the new start value. More...
 

Public Attributes

bool needNewGlobIDBeforeSend_
 The Generate-a-new-globalMsgID flag. More...
 
PersistentData persistentData_
 The persistent data assigned to the message instance. More...
 
System::u64 timestampNanos_
 The sending/receiving timestamp. More...
 
void * userData_
 The user data field. More...
 

Detailed Description

The part of the FIX message storing persistent data and helpers.

Constructor & Destructor Documentation

Engine::FIXMessageEx::FIXMessageEx ( )
inline

The constructor.

References generateNewGlobalId().

Member Function Documentation

System::u64 Engine::FIXMessageEx::generateNewGlobalId ( )
inline

Generates the new globalMsgID for the message.

References Engine::g_globalMsgIdGen, Engine::PersistentData::globalMsgID, Engine::GlobalMsgIdGen::newValue(), and persistentData_.

Referenced by FIXMessageEx().

void Engine::FIXMessageEx::generateNewGlobalIdBeforeSend ( )
inline

Generates a new globalMsgID for the message before message is sent.

It is called for the LiteFixMessage as a part of the sending process.

See Also
needNewGlobIDBeforeSend()

References Engine::g_globalMsgIdGen, Engine::PersistentData::globalMsgID, needNewGlobIDBeforeSend_, Engine::GlobalMsgIdGen::newValue(), and persistentData_.

static System::u64 Engine::FIXMessageEx::getCurrGlobalMsgId ( )
inlinestatic

Returns the last generated GlobalMsgId.

References Engine::GlobalMsgIdGen::curValue(), and Engine::g_globalMsgIdGen.

const PersistentData& Engine::FIXMessageEx::getPersistentData ( ) const
inline

Returns the persistent data from the message.

References persistentData_.

Referenced by Engine::MsgPipeElem::returnObj().

PersistentData& Engine::FIXMessageEx::getPersistentData ( )
inline

Returns the persistent data from the message.

References persistentData_.

const PersistentUserData& Engine::FIXMessageEx::getPersistentUserData ( ) const
inline

Returns the user part of the persistent data from the message.

References persistentData_, and Engine::PersistentData::userData.

PersistentUserData& Engine::FIXMessageEx::getPersistentUserData ( )
inline

Returns the user part of the persistent data from the message.

References persistentData_, and Engine::PersistentData::userData.

System::u64 Engine::FIXMessageEx::getTimestamp ( )
inline

Returns the sending/receiving timestamp.

References persistentData_, and Engine::PersistentData::timestampUsec.

void* Engine::FIXMessageEx::getUserData ( ) const
inline

Returns user data attached to the message instance.

Note
The data is not processed by the engine e.g. no clone, no persist, no load

References userData_.

bool Engine::FIXMessageEx::needNewGlobIDBeforeSend ( )
inline

Returns true if the message is configured to generate a new globalMsgID for the message before the message is sent.

References needNewGlobIDBeforeSend_.

static void Engine::FIXMessageEx::seedGlobalMsgId ( System::u64  globalMsgId)
inlinestatic

Initializes the global GlobalMsgId generator with the new start value.

References Engine::g_globalMsgIdGen, and Engine::GlobalMsgIdGen::reset().

void Engine::FIXMessageEx::setNeedNewGlobIDBeforeSend ( bool  enable)
inline

Configures the message to generate a new globalMsgID for the message before the message is sent or to skip the generation.

Parameters
enableif it is true generation will be enabled.

References needNewGlobIDBeforeSend_.

const void Engine::FIXMessageEx::setPersistentData ( const PersistentData persistentData)
inline

Sets the persistent data to the message.

The data will be stored in the in/out sessions logs with the message.

Parameters
persistentDatadata to assign

References persistentData_.

void Engine::FIXMessageEx::setPersistentUserData ( const PersistentUserData userData)
inline

Sets the user part of the persistent data to the message.

The data will be stored in the in/out sessions logs with the message.

Parameters
userDataThe user data to assign

References persistentData_, and Engine::PersistentData::userData.

void Engine::FIXMessageEx::setTimestamp ( System::u64  timestampUsec)
inline

Sets the sending/receiving timestamp.

References persistentData_, and Engine::PersistentData::timestampUsec.

Referenced by fix_algo::reorderSMHForMiax().

void Engine::FIXMessageEx::setUserData ( void *  userData)
inline

Attaches the user data to the message instance.

Note
The data is not processed by the engine e.g. no clone, no persist, no load

References userData_.

Member Data Documentation

bool Engine::FIXMessageEx::needNewGlobIDBeforeSend_

The Generate-a-new-globalMsgID flag.

See Also
setNeedNewGlobIDBeforeSend( enable )
needNewGlobIDBeforeSend()

Referenced by generateNewGlobalIdBeforeSend(), needNewGlobIDBeforeSend(), and setNeedNewGlobIDBeforeSend().

PersistentData Engine::FIXMessageEx::persistentData_
System::u64 Engine::FIXMessageEx::timestampNanos_

The sending/receiving timestamp.

void* Engine::FIXMessageEx::userData_

The user data field.

See Also
setUserData(userData)
getUserData()

Referenced by getUserData(), and setUserData().