ldas-tools-framecpp 3.0.4
 
Loading...
Searching...
No Matches
FrStruct.hh File Reference
#include <memory>
#include <boost/pointer_cast.hpp>
#include <boost/shared_ptr.hpp>
#include "framecpp/Common/FrameSpec.hh"
Include dependency graph for FrStruct.hh:
This graph shows which files directly or indirectly include this file:

Classes

class  Demote< FrameObjCurType, FrameObjPrevType >
 
struct  PreviousInfo< FrameObjectTypes >
 
class  Promote< FrameObjCurType, FrameObjPrevType >
 

Macros

#define CHECK_STRING_4(P, PA, C, CA, N)
 
#define CHECK_STRING(P, C, A, N)
 
#define CHECK_NUMBER_CONST(V, VA, C, N)
 
#define CHECK_NUMBER_4(P, PA, C, CA, N)
 
#define CHECK_NUMBER(P, C, A, N)
 
#define DEMOTE_TO_PREVIOUS_DIFF(CUR, PRE)
 
#define DEMOTE_TO_PREVIOUS(CUR)
 
#define DEMOTE_TO_SAME(CUR)
 
#define DEMOTE_TO_NULL(CUR)
 
#define PROMOTE_FROM_NOTHING(CUR)
 
#define PROMOTE_FROM_PREVIOUS_DIFF(CUR, PRE)
 
#define PROMOTE_FROM_PREVIOUS(CUR)
 
#define PROMOTE_TO_SAME_DIFF(CUR, PRE)
 
#define PROMOTE_TO_SAME(CUR)
 

Typedefs

typedef FrameCPP::Common::FrameSpec::Object FrObject
 
typedef FrameCPP::Common::FrameSpec::Info::frame_object_types FrameObjectTypes
 
typedef boost::shared_ptr< FrObjectframe_object_type
 
typedef frame_object_type mk_frame_object_ret_type
 

Functions

void AddressCheck (const void *LHS, const void *RHS, bool Sameness, bool Nullness, const std::string &Leader)
 
mk_frame_object_ret_type mk_frame_object (int SpecVersion, FrameCPP::Common::FrameSpec::Info::frame_object_types Type)
 
template<int V>
mk_frame_object_ret_type mk_frame_object (FrameObjectTypes Type)
 
template<int V>
void verify_downconvert (frame_object_type FrameObj, const std::string &Leader)
 
template<int V>
void verify_upconvert (frame_object_type FrameObj, const std::string &Leader)
 
template<typename FrameObjCurType, typename FrameObjPreType = typename PreviousInfo< FrameObjCurType >::type>
void DemoteToSame (frame_object_type FrameObj, int PreviousSpec, const std::string &Leader)
 
template<typename FrameObjCurType, typename FrameObjPreType = typename PreviousInfo< FrameObjCurType >::type>
void PromoteToSame (frame_object_type FrameObj, int CurrentSpec, int PreviousSpec, const std::string &Leader)
 

Variables

static FrameCPP::Common::IStreamNULL_ISTREAM
 

Macro Definition Documentation

◆ CHECK_NUMBER

#define CHECK_NUMBER ( P,
C,
A,
N )
Value:
CHECK_NUMBER_4( P, A, C, A, N )
static const char C
Definition FrSample.hh:57
#define CHECK_NUMBER_4(P, PA, C, CA, N)
Definition FrStruct.hh:57

◆ CHECK_NUMBER_4

#define CHECK_NUMBER_4 ( P,
PA,
C,
CA,
N )
Value:
BOOST_TEST_MESSAGE( Leader << "field: " #N ); \
BOOST_CHECK( C->CA( ) == P->PA( ) )

◆ CHECK_NUMBER_CONST

#define CHECK_NUMBER_CONST ( V,
VA,
C,
N )
Value:
BOOST_TEST_MESSAGE( Leader << "field: " #N ); \
BOOST_CHECK( V->VA( ) == C )
#define V

◆ CHECK_STRING

#define CHECK_STRING ( P,
C,
A,
N )
Value:
CHECK_STRING_4( P, A, C, A, N )
#define CHECK_STRING_4(P, PA, C, CA, N)
Definition FrStruct.hh:47

◆ CHECK_STRING_4

#define CHECK_STRING_4 ( P,
PA,
C,
CA,
N )
Value:
BOOST_TEST_MESSAGE( Leader << "field: " #N ); \
BOOST_CHECK( C->CA( ).compare( P->PA( ) ) == 0 )

◆ DEMOTE_TO_NULL

#define DEMOTE_TO_NULL ( CUR)
Value:
boost::shared_ptr< CUR > obj_( \
boost::dynamic_pointer_cast< CUR >( FrameObj ) ); \
\
Demote< CUR, CUR >::OutOfExistance( obj_, PREVIOUS_TEMPLATE_SPEC, Leader )

◆ DEMOTE_TO_PREVIOUS

#define DEMOTE_TO_PREVIOUS ( CUR)
Value:
#define DEMOTE_TO_PREVIOUS_DIFF(CUR, PRE)
Definition FrStruct.hh:178

◆ DEMOTE_TO_PREVIOUS_DIFF

#define DEMOTE_TO_PREVIOUS_DIFF ( CUR,
PRE )
Value:
typedef boost::shared_ptr< CUR > cast_type; \
typedef CUR cur_type; \
typedef PREVIOUS_NAMESPACE::PRE pre_type; \
\
cast_type current( \
boost::dynamic_pointer_cast< cast_type::element_type >( FrameObj ) ); \
\
current, PREVIOUS_TEMPLATE_SPEC, Leader ) )
static previous_type Previous(current_type Current, int PreviousSpecVersion, const std::string &Leader)
Definition FrStruct.hh:124
boost::shared_ptr< FrameObjPrevType > previous_type
Definition FrStruct.hh:104

◆ DEMOTE_TO_SAME

#define DEMOTE_TO_SAME ( CUR)
Value:
boost::shared_ptr< CUR > obj_( \
boost::dynamic_pointer_cast< CUR >( FrameObj ) ); \
\
Demote< CUR, PREVIOUS_NAMESPACE::CUR >::ToSame( \
obj_, PREVIOUS_TEMPLATE_SPEC, Leader )

◆ PROMOTE_FROM_NOTHING

#define PROMOTE_FROM_NOTHING ( CUR)
Value:
FrameObj, TEMPLATE_SPEC, PREVIOUS_TEMPLATE_SPEC, Leader )
static void FromNothing(frame_object_type FrameObj, int SpecVersion, int PreviousSpecVersion, const std::string &Leader)
Definition FrStruct.hh:234

◆ PROMOTE_FROM_PREVIOUS

#define PROMOTE_FROM_PREVIOUS ( CUR)
Value:
#define PROMOTE_FROM_PREVIOUS_DIFF(CUR, PRE)
Definition FrStruct.hh:354

◆ PROMOTE_FROM_PREVIOUS_DIFF

#define PROMOTE_FROM_PREVIOUS_DIFF ( CUR,
PRE )
Value:
typedef CUR cur_type; \
typedef PREVIOUS_NAMESPACE::PRE pre_type; \
\
\
Promote< cur_type, pre_type >::FromPrevious( FrameObj, \
TEMPLATE_SPEC, \
promoted, \
PREVIOUS_TEMPLATE_SPEC, \
previous, \
Leader )
boost::shared_ptr< FrameObjPrevType > previous_type
Definition FrStruct.hh:230
boost::shared_ptr< FrameObjCurType > current_type
Definition FrStruct.hh:228

◆ PROMOTE_TO_SAME

#define PROMOTE_TO_SAME ( CUR)
Value:
#define PROMOTE_TO_SAME_DIFF(CUR, PRE)
Definition FrStruct.hh:370

◆ PROMOTE_TO_SAME_DIFF

#define PROMOTE_TO_SAME_DIFF ( CUR,
PRE )
Value:
FrameObj, TEMPLATE_SPEC, PREVIOUS_TEMPLATE_SPEC, Leader )
static void ToSame(frame_object_type FrameObj, int SpecVersion, int PreviousSpecVersion, const std::string &Leader)
Definition FrStruct.hh:296

Typedef Documentation

◆ frame_object_type

typedef boost::shared_ptr< FrObject > frame_object_type

◆ FrameObjectTypes

◆ FrObject

◆ mk_frame_object_ret_type

Function Documentation

◆ AddressCheck()

void AddressCheck ( const void * LHS,
const void * RHS,
bool Sameness,
bool Nullness,
const std::string & Leader )
inline

◆ DemoteToSame()

template<typename FrameObjCurType, typename FrameObjPreType = typename PreviousInfo< FrameObjCurType >::type>
void DemoteToSame ( frame_object_type FrameObj,
int PreviousSpec,
const std::string & Leader )

◆ mk_frame_object() [1/2]

template<int V>
mk_frame_object_ret_type mk_frame_object ( FrameObjectTypes Type)

◆ mk_frame_object() [2/2]

◆ PromoteToSame()

template<typename FrameObjCurType, typename FrameObjPreType = typename PreviousInfo< FrameObjCurType >::type>
void PromoteToSame ( frame_object_type FrameObj,
int CurrentSpec,
int PreviousSpec,
const std::string & Leader )

◆ verify_downconvert()

template<int V>
void verify_downconvert ( frame_object_type FrameObj,
const std::string & Leader )

◆ verify_upconvert()

template<int V>
void verify_upconvert ( frame_object_type FrameObj,
const std::string & Leader )

Variable Documentation

◆ NULL_ISTREAM

FrameCPP::Common::IStream* NULL_ISTREAM
static
Initial value:
=
Definition IOStream.hh:232