1#ifndef COIN_SOSUBDETAIL_H
2#define COIN_SOSUBDETAIL_H
36#include <Inventor/details/SoDetail.h>
37#include <Inventor/C/tidbits.h>
38#include <Inventor/SbName.h>
44#define SO_DETAIL_HEADER(_class_) \
46 virtual SoType getTypeId(void) const; \
47 static SoType getClassTypeId(void); \
49 static SoType classTypeId; \
54 static void cleanupClass(void) { _class_::classTypeId STATIC_SOTYPE_INIT; }
58#define SO_DETAIL_SOURCE(_class_) \
59SoType _class_::classTypeId STATIC_SOTYPE_INIT; \
66SoType _class_::getTypeId(void) const { return _class_::classTypeId; } \
72SoType _class_::getClassTypeId(void) { return _class_::classTypeId; }
76#define SO_DETAIL_INIT_CLASS(_class_, _parentclass_) \
79 assert(_class_::classTypeId == SoType::badType()); \
81 assert(_parentclass_::getClassTypeId() != SoType::badType()); \
83 _class_::classTypeId = \
84 SoType::createType(_parentclass_::getClassTypeId(), \
85 SO__QUOTE(_class_)); \
89 cc_coin_atexit(reinterpret_cast<coin_atexit_f *>(_class_::cleanupClass)); \