B2BITS FIX Antenna HFT  1.0.16
 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::FIXFieldValue Struct Reference

It is used for storing the Contents information (data + length). More...

#include <B2BITS_FIXFieldValue.h>

Public Member Functions

void clear ()
 Resets internal storage. More...
 
 FIXFieldValue ()
 Constructs empty sequence. More...
 
 FIXFieldValue (const char *str)
 Constructs object from null-terminated C-string. More...
 
 FIXFieldValue (const char *data, std::size_t length)
 Constructs object from char chain. More...
 
 FIXFieldValue (const FIXFieldValue &fieldValue)
 Copy constructor. More...
 
bool isEmpty () const
 Verifies is sequence empty. More...
 
bool operator!= (const FIXFieldValue &fieldValue) const
 Compares two object. More...
 
bool operator== (const FIXFieldValue &fieldValue) const
 Compares two object. More...
 
bool operator== (const char *val) const
 Compares with null-terminated char* std::string. More...
 
int toSigned () const
 Returns signed numeric value of sequence. More...
 
System::i64 toSigned64 () const
 Returns signed 64bit numeric value of sequence. More...
 
unsigned int toUnsigned () const
 Returns unsigned numeric value of sequence. More...
 
System::u64 toUnsigned64 () const
 Returns signed 64bit numeric value of sequence. More...
 

Static Public Member Functions

static int compare (const FIXFieldValue &firstValue, const FIXFieldValue &secondValue)
 Compares two sequences in 'std::strcmp' style. More...
 

Public Attributes

const char * data_
 Pointer to byte array. More...
 
std::size_t length_
 Length of sequence. More...
 

Detailed Description

It is used for storing the Contents information (data + length).

Constructor & Destructor Documentation

Engine::FIXFieldValue::FIXFieldValue ( )

Constructs empty sequence.

Engine::FIXFieldValue::FIXFieldValue ( const char *  str)
explicit

Constructs object from null-terminated C-string.

Engine::FIXFieldValue::FIXFieldValue ( const char *  data,
std::size_t  length 
)

Constructs object from char chain.

Engine::FIXFieldValue::FIXFieldValue ( const FIXFieldValue fieldValue)

Copy constructor.

Member Function Documentation

void Engine::FIXFieldValue::clear ( )

Resets internal storage.

static int Engine::FIXFieldValue::compare ( const FIXFieldValue firstValue,
const FIXFieldValue secondValue 
)
static

Compares two sequences in 'std::strcmp' style.

Parameters
firstValuelvalue
secondValuervalue
bool Engine::FIXFieldValue::isEmpty ( ) const
inline

Verifies is sequence empty.

References length_.

bool Engine::FIXFieldValue::operator!= ( const FIXFieldValue fieldValue) const

Compares two object.

Based on compare() member.

Parameters
fieldValueInstance of FIXFieldValue to compare with.
bool Engine::FIXFieldValue::operator== ( const FIXFieldValue fieldValue) const

Compares two object.

Based on compare() member.

Parameters
fieldValueInstance of FIXFieldValue to compare with.
bool Engine::FIXFieldValue::operator== ( const char *  val) const

Compares with null-terminated char* std::string.

Based on compare() member.

Parameters
valnull-terminated std::string to compare with.
int Engine::FIXFieldValue::toSigned ( ) const

Returns signed numeric value of sequence.

System::i64 Engine::FIXFieldValue::toSigned64 ( ) const

Returns signed 64bit numeric value of sequence.

Exceptions
Utils::ExceptionIf value cannot be converted
unsigned int Engine::FIXFieldValue::toUnsigned ( ) const

Returns unsigned numeric value of sequence.

Exceptions
Utils::ExceptionIf value cannot be converted
System::u64 Engine::FIXFieldValue::toUnsigned64 ( ) const

Returns signed 64bit numeric value of sequence.

Exceptions
Utils::ExceptionIf value cannot be converted

Member Data Documentation

const char* Engine::FIXFieldValue::data_
std::size_t Engine::FIXFieldValue::length_