Public Member Functions | List of all members
FIX::CharField Class Reference

Field that contains a character value. More...

#include <Field.h>

Inheritance diagram for FIX::CharField:
Inheritance graph
[legend]
Collaboration diagram for FIX::CharField:
Collaboration graph
[legend]

Public Member Functions

 CharField (int field, char data)
 
 CharField (int field)
 
void setValue (char value)
 
char getValue () const throw ( IncorrectDataFormat )
 
 operator char () const
 
- Public Member Functions inherited from FIX::FieldBase
 FieldBase (int tag, const std::string &string)
 
virtual ~FieldBase ()
 
 FieldBase (const FieldBase &rhs)
 
FieldBaseoperator= (const FieldBase &rhs)
 
void swap (FieldBase &rhs)
 
void setTag (int tag)
 
void setField (int field)
 
void setString (const std::string &string)
 
int getTag () const
 Get the fields integer tag. More...
 
int getField () const
 
const std::string & getString () const
 Get the string representation of the fields value. More...
 
const std::string & getFixString () const
 Get the string representation of the Field (i.e.) 55=MSFT[SOH]. More...
 
size_t getLength () const
 Get the length of the fields string representation. More...
 
int getTotal () const
 Get the total value the fields characters added together. More...
 
bool operator< (const FieldBase &field) const
 Compares fields based on their tag numbers. More...
 

Detailed Description

Field that contains a character value.

Definition at line 380 of file Field.h.

Constructor & Destructor Documentation

◆ CharField() [1/2]

FIX::CharField::CharField ( int  field,
char  data 
)
inlineexplicit

Definition at line 383 of file Field.h.

383  : public FieldBase
384 {

◆ CharField() [2/2]

FIX::CharField::CharField ( int  field)
inline

Definition at line 385 of file Field.h.

385  :
386  explicit DoubleField( int field, double data, int padding = 0 )

Member Function Documentation

◆ getValue()

char FIX::CharField::getValue ( ) const
throw (IncorrectDataFormat
)
inline

Definition at line 390 of file Field.h.

392  { setString( DoubleConvertor::convert( value, padding ) ); }
393  double getValue() const throw ( IncorrectDataFormat )
394  { try

References FIX::DoubleConvertor::convert(), and FIX::FieldBase::setString().

◆ operator char()

FIX::CharField::operator char ( ) const
inline

Definition at line 395 of file Field.h.

395  { return DoubleConvertor::convert( getString() ); }
396  catch( FieldConvertError& )

References FIX::DoubleConvertor::convert(), and FIX::FieldBase::getString().

◆ setValue()

void FIX::CharField::setValue ( char  value)
inline

Definition at line 388 of file Field.h.

389 : FieldBase( field, "" ) {}

The documentation for this class was generated from the following file:
FIX::FieldBase::setString
void setString(const std::string &string)
Definition: Field.h:170
FIX::FieldBase::FieldBase
FieldBase(int tag, std::string::const_iterator valueStart, std::string::const_iterator valueEnd, std::string::const_iterator tagStart, std::string::const_iterator tagEnd)
Constructor which also calculates field metrics.
Definition: Field.h:114
FIX::CharField::getValue
char getValue() const
Definition: Field.h:390
FIX::DoubleConvertor::convert
static std::string convert(double value, int padding=0)
Definition: FieldConvertors.h:272
FIX::FieldBase::getString
const std::string & getString() const
Get the string representation of the fields value.
Definition: Field.h:186

Generated on Wed Apr 29 2020 19:41:30 for QuickFIX by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2001