source: XMLIO_V2/dev/dev_rv/src/xmlio/declare_group.hpp @ 168

Last change on this file since 168 was 168, checked in by hozdoba, 13 years ago
File size: 1.8 KB
Line 
1#ifndef __XMLIO_DECLARE_GROUP__
2#define __XMLIO_DECLARE_GROUP__
3
4/// ///////////////////////////// Macros ///////////////////////////// ///
5
6#define DECLARE_GROUP(type)                                           \
7   class type##Group                                                  \
8      : public CGroupTemplate<type, type##Group, type##Attributes>    \
9   {                                                                  \
10      public:                                                         \
11         typedef type              RelChild;                          \
12         typedef type##Group       RelGroup;                          \
13         typedef type##Attributes  RelAttributes;                     \
14                                                                      \
15         type##Group(void)                                            \
16            : CGroupTemplate<RelChild, RelGroup, RelAttributes> ()    \
17         { /* Ne rien faire de plus */ }                              \
18         type##Group(const StdString& _id)                            \
19            : CGroupTemplate<RelChild, RelGroup, RelAttributes> (_id) \
20         { /* Ne rien faire de plus */ }                              \
21                                                                      \
22         static ENodeType GetType(void)                               \
23         { return static_cast<ENodeType>(RelChild::GetType()+1); }    \
24                                                                      \
25         virtual ~type##Group(void)                                   \
26         { /* Ne rien faire de plus */ }                              \
27   };                                                                 \
28   typedef type##Group type##Definition
29
30#endif // __XMLIO_DECLARE_GROUP__
Note: See TracBrowser for help on using the repository browser.