#include <OSGMultiFunctorStore.h>
Types | |
| typedef FunctorStore::iterator | FunctorStoreIt |
| typedef FunctorStore::const_iterator | FunctorStoreConstIt |
| typedef std::vector< FunctorStoreIt > | FunctorMap |
| typedef FunctorMap::iterator | FunctorMapIt |
| typedef FunctorMap::const_iterator | FunctorMapConstIt |
| *typedef std::list< Functor > | FunctorStore |
Public Member Functions | |
Constructors | |
| * | MultiFunctorStore (void) |
Destructor | |
| * | ~MultiFunctorStore (void) |
Empty | |
| *bool | empty (void) const |
Functor Registration | |
| *void | regFunctor (const Functor &refFunc, const FieldContainerType &refType) |
| void | unregFunctor (const FieldContainerType &refType) |
| void | regDefaultFunctor (const Functor &refFunc) |
| void | unregDefaultFunctor (void) |
Functor Access | |
| *Functor * | getFunctor (const FieldContainerType &refType) |
| Functor * | getDefaultFunctor (void) |
Public Attributes | |
Types | |
| *typedef NewActionTypes::Functor | Functor |
Private Attributes | |
| FunctorStore | _funcStore |
| FunctorMap | _funcMap |
| Functor | _defaultFunc |
| bool | _bHasDefaultFunctor |
Definition at line 54 of file OSGMultiFunctorStore.h.
|
|
Definition at line 113 of file OSGMultiFunctorStore.h. |
|
|
Definition at line 114 of file OSGMultiFunctorStore.h. |
|
|
Definition at line 116 of file OSGMultiFunctorStore.h. |
|
|
Definition at line 117 of file OSGMultiFunctorStore.h. |
|
|
Definition at line 118 of file OSGMultiFunctorStore.h. |
|
|
Definition at line 45 of file OSGMultiFunctorStore.inl. 00046 : _funcStore ( ), 00047 _funcMap ( ), 00048 _defaultFunc ( ), 00049 _bHasDefaultFunctor(false) 00050 { 00051 }
|
|
|
Definition at line 57 of file OSGMultiFunctorStore.inl.
|
|
|
Definition at line 65 of file OSGMultiFunctorStore.inl. References _bHasDefaultFunctor, and _funcStore. 00066 { 00067 return _funcStore.empty() && !_bHasDefaultFunctor; 00068 }
|
|
||||||||||||
|
Definition at line 74 of file OSGMultiFunctorStore.inl. References _funcMap, _funcStore, and osg::TypeBase::getId(). 00076 { 00077 _funcStore.push_front(refFunc); 00078 00079 if(_funcMap.size() <= refType.getId()) 00080 { 00081 _funcMap.resize(refType.getId() + 1, _funcStore.end()); 00082 } 00083 00084 _funcMap[refType.getId()] = _funcStore.begin(); 00085 }
|
|
|
Definition at line 88 of file OSGMultiFunctorStore.inl. References _funcMap, _funcStore, and osg::TypeBase::getId(). 00089 { 00090 FunctorStoreIt funcIter = _funcMap[refType.getId()]; 00091 00092 if(funcIter != _funcStore.end()) 00093 _funcStore.erase(funcIter); 00094 00095 _funcMap[refType.getId()] = _funcStore.end(); 00096 }
|
|
|
Definition at line 99 of file OSGMultiFunctorStore.inl. References _bHasDefaultFunctor, and _defaultFunc. 00100 { 00101 _defaultFunc = refFunc; 00102 _bHasDefaultFunctor = true; 00103 }
|
|
|
Definition at line 106 of file OSGMultiFunctorStore.inl. References _bHasDefaultFunctor. 00107 { 00108 _bHasDefaultFunctor = false; 00109 }
|
|
|
Definition at line 115 of file OSGMultiFunctorStore.inl. References _bHasDefaultFunctor, _defaultFunc, _funcMap, _funcStore, Functor, and osg::TypeBase::getId(). 00116 { 00117 Functor *pRetFunc = NULL; 00118 FunctorStoreIt funcIter = _funcStore.end(); 00119 00120 if(refType.getId() < _funcMap.size()) 00121 { 00122 funcIter = _funcMap[refType.getId()]; 00123 } 00124 00125 if(funcIter != _funcStore.end()) 00126 { 00127 pRetFunc = &(*funcIter); 00128 } 00129 else if(_bHasDefaultFunctor) 00130 { 00131 pRetFunc = &_defaultFunc; 00132 } 00133 00134 return pRetFunc; 00135 }
|
|
|
Definition at line 138 of file OSGMultiFunctorStore.inl. References _bHasDefaultFunctor, _defaultFunc, and Functor. 00139 { 00140 Functor *pRetFunc = NULL; 00141 00142 if(_bHasDefaultFunctor) 00143 { 00144 pRetFunc = &_defaultFunc; 00145 } 00146 00147 return pRetFunc; 00148 }
|
|
|
Definition at line 62 of file OSGMultiFunctorStore.h. Referenced by getDefaultFunctor(), and getFunctor(). |
|
|
Definition at line 112 of file OSGMultiFunctorStore.h. |
|
|
Definition at line 123 of file OSGMultiFunctorStore.h. Referenced by empty(), getFunctor(), regFunctor(), and unregFunctor(). |
|
|
Definition at line 124 of file OSGMultiFunctorStore.h. Referenced by getFunctor(), regFunctor(), and unregFunctor(). |
|
|
Definition at line 126 of file OSGMultiFunctorStore.h. Referenced by getDefaultFunctor(), getFunctor(), and regDefaultFunctor(). |
|
|
Definition at line 127 of file OSGMultiFunctorStore.h. Referenced by empty(), getDefaultFunctor(), getFunctor(), regDefaultFunctor(), and unregDefaultFunctor(). |
1.4.3