liblcf
Loading...
Searching...
No Matches
lcf::TypedField< S, T > Struct Template Reference

#include <reader_struct.h>

Inheritance diagram for lcf::TypedField< S, T >:
Collaboration diagram for lcf::TypedField< S, T >:

Public Types

typedef S struct_type

Public Member Functions

void ReadLcf (S &obj, LcfReader &stream, uint32_t length) const
void WriteLcf (const S &obj, LcfWriter &stream) const
int LcfSize (const S &obj, LcfWriter &stream) const
void WriteXml (const S &obj, XmlWriter &stream) const
void BeginXml (S &obj, XmlReader &stream) const
void ParseXml (S &obj, const std::string &data) const
bool IsDefault (const S &a, const S &b, bool) const
 TypedField (T S::*ref, int id, const char *name, bool present_if_default, bool is2k3)
bool isPresentIfDefault (bool db_is2k3) const

Public Attributes

T S::* ref
const char *const name
int id
bool present_if_default
bool is2k3

Detailed Description

template<class S, class T>
struct lcf::TypedField< S, T >

TypedField class template.

Definition at line 400 of file reader_struct.h.

Member Typedef Documentation

◆ struct_type

template<class S>
typedef S lcf::Field< S >::struct_type
inherited

Definition at line 368 of file reader_struct.h.

Constructor & Destructor Documentation

◆ TypedField()

template<class S, class T>
lcf::TypedField< S, T >::TypedField ( T S::* ref,
int id,
const char * name,
bool present_if_default,
bool is2k3 )
inline

Definition at line 427 of file reader_struct.h.

References lcf::Field< S >::Field(), lcf::Field< S >::id, lcf::Field< S >::is2k3, lcf::Field< S >::name, lcf::Field< S >::present_if_default, and ref.

Here is the call graph for this function:

Member Function Documentation

◆ BeginXml()

template<class S, class T>
void lcf::TypedField< S, T >::BeginXml ( S & obj,
XmlReader & stream ) const
inlinevirtual

Implements lcf::Field< S >.

Definition at line 417 of file reader_struct.h.

References ref.

◆ IsDefault()

template<class S, class T>
bool lcf::TypedField< S, T >::IsDefault ( const S & a,
const S & b,
bool  ) const
inlinevirtual

Implements lcf::Field< S >.

Definition at line 423 of file reader_struct.h.

References ref.

Referenced by lcf::DatabaseVersionField< S, T >::IsDefault().

Here is the caller graph for this function:

◆ isPresentIfDefault()

template<class S>
bool lcf::Field< S >::isPresentIfDefault ( bool db_is2k3) const
inlineinherited

Definition at line 383 of file reader_struct.h.

References present_if_default.

Referenced by lcf::Struct< S >::LcfSize(), and lcf::Struct< S >::WriteLcf().

Here is the caller graph for this function:

◆ LcfSize()

template<class S, class T>
int lcf::TypedField< S, T >::LcfSize ( const S & obj,
LcfWriter & stream ) const
inlinevirtual

Implements lcf::Field< S >.

Definition at line 409 of file reader_struct.h.

References ref.

Referenced by lcf::DatabaseVersionField< S, T >::LcfSize().

Here is the caller graph for this function:

◆ ParseXml()

template<class S, class T>
void lcf::TypedField< S, T >::ParseXml ( S & obj,
const std::string & data ) const
inlinevirtual

Implements lcf::Field< S >.

Definition at line 420 of file reader_struct.h.

References ref.

◆ ReadLcf()

template<class S, class T>
void lcf::TypedField< S, T >::ReadLcf ( S & obj,
LcfReader & stream,
uint32_t length ) const
inlinevirtual

Implements lcf::Field< S >.

Definition at line 403 of file reader_struct.h.

References ref.

◆ WriteLcf()

template<class S, class T>
void lcf::TypedField< S, T >::WriteLcf ( const S & obj,
LcfWriter & stream ) const
inlinevirtual

Implements lcf::Field< S >.

Definition at line 406 of file reader_struct.h.

References ref.

◆ WriteXml()

template<class S, class T>
void lcf::TypedField< S, T >::WriteXml ( const S & obj,
XmlWriter & stream ) const
inlinevirtual

Implements lcf::Field< S >.

Definition at line 412 of file reader_struct.h.

References lcf::Field< S >::name, and ref.

Member Data Documentation

◆ id

◆ is2k3

◆ name

template<class S>
const char* const lcf::Field< S >::name
inherited

◆ present_if_default

template<class S>
bool lcf::Field< S >::present_if_default
inherited

◆ ref

template<class S, class T>
T S::* lcf::TypedField< S, T >::ref

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