DART  6.7.3
TemplateJoinerDispatchMacro.hpp File Reference

Go to the source code of this file.

Macros

#define DETAIL_DART_COMMON_IRREGULAR_TEMPLATEJOINERDISPATCH_IMPL(ReturnType, ClassName, Function, Suffix, SpecializationChecker, Args)
 This macro provides the implementation for most of the member functions in common::CompositeJoiner, dynamics::NodeManagerJoinerForBodyNode, and NodeManagerJoinerForSkeleton. More...
 
#define DETAIL_DART_COMMON_TEMPLATEJOINERDISPATCH_IMPL(ReturnType, ClassName, Function, Suffix, Args)    DETAIL_DART_COMMON_IRREGULAR_TEMPLATEJOINERDISPATCH_IMPL(ReturnType, ClassName, Function, Suffix, isSpecializedFor, Args)
 

Macro Definition Documentation

◆ DETAIL_DART_COMMON_IRREGULAR_TEMPLATEJOINERDISPATCH_IMPL

#define DETAIL_DART_COMMON_IRREGULAR_TEMPLATEJOINERDISPATCH_IMPL (   ReturnType,
  ClassName,
  Function,
  Suffix,
  SpecializationChecker,
  Args 
)
Value:
template <class Base1, class Base2>\
template <class T>\
ReturnType ClassName <Base1, Base2>:: Function Suffix\
{\
if(Base1::template SpecializationChecker <T>())\
return Base1::template Function <T> Args ;\
\
return Base2::template Function <T> Args ;\
}

This macro provides the implementation for most of the member functions in common::CompositeJoiner, dynamics::NodeManagerJoinerForBodyNode, and NodeManagerJoinerForSkeleton.

The member functions of those classes share essentially the same logic, so it makes sense to have a single macro that provides the implementation for all of them.

◆ DETAIL_DART_COMMON_TEMPLATEJOINERDISPATCH_IMPL

#define DETAIL_DART_COMMON_TEMPLATEJOINERDISPATCH_IMPL (   ReturnType,
  ClassName,
  Function,
  Suffix,
  Args 
)     DETAIL_DART_COMMON_IRREGULAR_TEMPLATEJOINERDISPATCH_IMPL(ReturnType, ClassName, Function, Suffix, isSpecializedFor, Args)