1 /*---------------------------------------------------------------------------*\
5 * Copyright (C) 2003 by the OpenSG Forum *
9 * contact: dirk@opensg.org, gerrit.voss@vossg.org, jbehr@zgdv.de *
11 \*---------------------------------------------------------------------------*/
12 /*---------------------------------------------------------------------------*\
15 * This library is free software; you can redistribute it and/or modify it *
16 * under the terms of the GNU Library General Public License as published *
17 * by the Free Software Foundation, version 2. *
19 * This library is distributed in the hope that it will be useful, but *
20 * WITHOUT ANY WARRANTY; without even the implied warranty of *
21 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
22 * Library General Public License for more details. *
24 * You should have received a copy of the GNU Library General Public *
25 * License along with this library; if not, write to the Free Software *
26 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. *
28 \*---------------------------------------------------------------------------*/
29 /*---------------------------------------------------------------------------*\
37 \*---------------------------------------------------------------------------*/
39 #ifndef _OSGFIELDFORWARDS_H_
40 #define _OSGFIELDFORWARDS_H_
45 #include <boost/function.hpp>
46 #include <boost/shared_ptr.hpp>
48 #include "OSGConfig.h"
49 #include "OSGBaseTypes.h"
50 #include "OSGBinaryDataHandler.h"
54 #ifndef DOXYGEN_SHOULD_SKIP_THIS
58 template<class ValueT
, Int32 iNamespace
>
61 template<class ValueT
, Int32 iNamespace
, class AllocT
>
64 template<class ValueT
,
65 typename RefCountPolicy
,
69 template<class ValueT
,
70 typename RefCountPolicy
,
74 template<class ValueT
,
75 typename RefCountPolicy
,
77 class ParentPointerSField
;
79 template<class ValueT
,
80 typename RefCountPolicy
,
82 class ParentPointerMField
;
84 template<class ValueT
,
85 typename RefCountPolicy
,
87 class ChildPointerSField
;
89 template<class ValueT
,
90 typename RefCountPolicy
,
92 class ChildPointerMField
;
94 class FieldDescriptionBase
;
95 class ReflexiveContainer
;
98 class EditFieldHandle
;
100 typedef boost::shared_ptr
<GetFieldHandle
> GetFieldHandlePtr
;
101 typedef boost::shared_ptr
<EditFieldHandle
> EditFieldHandlePtr
;
103 typedef EditFieldHandlePtr(ReflexiveContainer::*FieldEditMethod
)(void );
104 typedef GetFieldHandlePtr (ReflexiveContainer::*FieldGetMethod
)(void) const;
106 typedef EditFieldHandlePtr(ReflexiveContainer::*FieldIndexEditMethod
)(UInt32
);
107 typedef GetFieldHandlePtr (ReflexiveContainer::*FieldIndexGetMethod
)(
110 /*! \ingroup GrpBaseFieldContainerBase
113 EditFieldHandlePtr(OSG::ReflexiveContainer::*FieldEditMethodSig
)(void);
115 /*! \ingroup GrpBaseFieldContainerBase
118 GetFieldHandlePtr (OSG::ReflexiveContainer::*FieldGetMethodSig
)(void) const;
121 /*! \ingroup GrpBaseFieldContainerBase
123 typedef EditFieldHandlePtr (OSG::ReflexiveContainer::*FieldIndexEditMethodSig
)(
126 /*! \ingroup GrpBaseFieldContainerBase
128 typedef GetFieldHandlePtr (OSG::ReflexiveContainer::*FieldIndexGetMethodSig
)(
131 /*! \ingroup GrpBaseFieldContainerBase
133 #ifdef FDESC_USE_BOOST
134 typedef boost::function
<Field
*(OSG::ReflexiveContainer
*)> FieldEditMethod
;
136 typedef EditFieldHandlePtr (OSG::ReflexiveContainer::*FieldEditMethod
)(void );
140 /*! \ingroup GrpBaseFieldContainerBase
142 #ifdef FDESC_USE_BOOST
143 typedef boost::function
<
144 const Field
*(const OSG::ReflexiveContainer
*)> FieldGetMethod
;
146 typedef GetFieldHandlePtr(OSG::ReflexiveContainer::*FieldGetMethod
)(void) const;
150 /*! \ingroup GrpBaseFieldContainerBase
152 #ifdef FDESC_USE_BOOST
153 typedef boost::function
<
154 Field
*(OSG::ReflexiveContainer
*, int)> FieldIndexEditMethod
;
156 typedef EditFieldHandlePtr (OSG::ReflexiveContainer::*FieldIndexEditMethod
)(
161 /*! \ingroup GrpBaseFieldContainerBase
163 #ifdef FDESC_USE_BOOST
164 typedef boost::function
<
165 const Field
*(const OSG::ReflexiveContainer
*,
166 int )> FieldIndexGetMethod
;
168 typedef GetFieldHandlePtr (OSG::ReflexiveContainer::*FieldIndexGetMethod
)(
172 typedef boost::function
<
173 FieldDescriptionBase
* (
174 const Char8
*szFieldname
,
176 FieldEditMethod fEditMethod
,
177 FieldGetMethod fGetMethod
) > FieldDescCreator
;
179 typedef boost::function
<
180 FieldDescriptionBase
* (
181 const Char8
*szFieldname
,
183 FieldIndexEditMethod fEditMethod
,
184 FieldIndexGetMethod fGetMethod
) > IndexedFieldDescCreator
;
188 #endif //DOXYGEN_SHOULD_SKIP_THIS
192 #endif /* _OSGFIELDFORWARDS_H_ */