VR-Link API Documentation for HLA 1.3
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Classes | Macros
rrbIffEncoder.h File Reference

This file provides a declaration of the class DtRRBIffEncoder. More...

Go to the source code of this file.

Classes

class  DtRRBIffEncoder
 

Macros

#define DtDECLARE_RRB_IFF_ATTR_ENCODER(attrName)   DtDECLARE_ATTR_ENCODER(DtIffStateRepository, attrName)
 This one can be used to declare the attribute decoding functions, which are static members of DtNatoIffEncoder. More...
 
#define DtDECLARE_RRB_IFF_ATTR_CHECKER(attrName)   DtDECLARE_ATTR_CHECKER(DtIffStateRepository, attrName)
 
#define DtDEFINE_SIMPLE_RRB_ATTR_CHECKER(encClass, stateRepClass, attrName, inspector)
 This macro is used to define simple attribute checker functions (members of a derived DtHlaStateEncoder that check whether a particular attribute is out of date.) The simple implementation is to just compare the values returned by the two StateReps' inspector functions. More...
 
#define DtDEFINE_SIMPLE_RRB_IFF_ATTR_CHECKER(attrName, inspector)
 This macro is used to define simple attribute checking functions (members of a derived DtHlaStateEncoder that check whether a particular attribute's update condition has been met. More...
 
#define DtDEFINE_SIMPLE_RRB_ATTR_ENCODER(encClass, stateRepClass, attrName, netType, inspector)
 These macros are used to define simple attribute encoder functions (members of a derived DtHlaStateEncoder that encode individual attributes). More...
 
#define DtDEFINE_SIMPLE_RRB_IFF_ATTR_ENCODER(attrName, netType, mutator)
 This one can be used to define a slightly-less-simple attribute decoder that requires an explicit cast to convert from the FOM representation to the native representation expected by the mutator. More...
 

Detailed Description

This file provides a declaration of the class DtRRBIffEncoder.

Macro Definition Documentation

#define DtDECLARE_RRB_IFF_ATTR_CHECKER (   attrName)    DtDECLARE_ATTR_CHECKER(DtIffStateRepository, attrName)
#define DtDECLARE_RRB_IFF_ATTR_ENCODER (   attrName)    DtDECLARE_ATTR_ENCODER(DtIffStateRepository, attrName)

This one can be used to declare the attribute decoding functions, which are static members of DtNatoIffEncoder.

This uses a more general macro defined in hStateEncoder.h.

#define DtDEFINE_SIMPLE_RRB_ATTR_CHECKER (   encClass,
  stateRepClass,
  attrName,
  inspector 
)
Value:
bool encClass::need##attrName(const stateRepClass& stateRep, \
const stateRepClass& asSeenByRemote) \
{ \
return (bool) !(stateRep.rrb()->inspector() == asSeenByRemote.rrb()->inspector()); \
}
static const xmlChar * attrName
Definition: xmlFedTags.h:116

This macro is used to define simple attribute checker functions (members of a derived DtHlaStateEncoder that check whether a particular attribute is out of date.) The simple implementation is to just compare the values returned by the two StateReps' inspector functions.

#define DtDEFINE_SIMPLE_RRB_ATTR_ENCODER (   encClass,
  stateRepClass,
  attrName,
  netType,
  inspector 
)
Value:
void encClass::encode##attrName(const stateRepClass& rep, \
RTI::AttributeHandleValuePairSet* attrs, \
RTI::AttributeHandle attrHandle) \
{ \
netType netVal; \
netVal = rep.rrb()->inspector(); \
attrs->add(attrHandle, (char*) &netVal, sizeof(netType)); \
}
static const xmlChar * attrName
Definition: xmlFedTags.h:116

These macros are used to define simple attribute encoder functions (members of a derived DtHlaStateEncoder that encode individual attributes).

The simple encoding is just to implicitly convert the value returned by the inspector to a netType, and add it to the ahvps.

#define DtDEFINE_SIMPLE_RRB_IFF_ATTR_CHECKER (   attrName,
  inspector 
)
Value:
#define DtDEFINE_SIMPLE_RRB_ATTR_CHECKER(encClass, stateRepClass, attrName, inspector)
This macro is used to define simple attribute checker functions (members of a derived DtHlaStateEncod...
Definition: rrbIffEncoder.h:28
Defines a protocol independent repository of attributes for IFF objects.
Definition: iffStateRepository.h:39
static const xmlChar * attrName
Definition: xmlFedTags.h:116
Definition: rrbIffEncoder.h:74

This macro is used to define simple attribute checking functions (members of a derived DtHlaStateEncoder that check whether a particular attribute's update condition has been met.

The "simple" implementation is to just compare the values returned by the two StateReps' inspector functions to see if they differ.

#define DtDEFINE_SIMPLE_RRB_IFF_ATTR_ENCODER (   attrName,
  netType,
  mutator 
)
Value:
attrName, netType, mutator)
Defines a protocol independent repository of attributes for IFF objects.
Definition: iffStateRepository.h:39
#define DtDEFINE_SIMPLE_RRB_ATTR_ENCODER(encClass, stateRepClass, attrName, netType, inspector)
These macros are used to define simple attribute encoder functions (members of a derived DtHlaStateEn...
Definition: rrbIffEncoder.h:51
static const xmlChar * attrName
Definition: xmlFedTags.h:116
Definition: rrbIffEncoder.h:74

This one can be used to define a slightly-less-simple attribute decoder that requires an explicit cast to convert from the FOM representation to the native representation expected by the mutator.

Arguments are the same as the macro above, with a fourth argument which is a cast expression to be used to cast the "net" type to the type expected by the mutator.


Document ID: Generated on Thu Oct 16 00:12:25 EDT 2025 from SVN revision 280738
Copyright © 1992-2025 MAK Technologies. All Rights Reserved (www.mak.com)