1 | #ifndef __XMLIO_CTransformation__ |
---|
2 | #define __XMLIO_CTransformation__ |
---|
3 | |
---|
4 | /// xios headers /// |
---|
5 | #include "xmlioserver_spl.hpp" |
---|
6 | #include "attribute_enum.hpp" |
---|
7 | #include "attribute_enum_impl.hpp" |
---|
8 | #include "attribute_array.hpp" |
---|
9 | #include "declare_attribute.hpp" |
---|
10 | #include "object_template.hpp" |
---|
11 | #include "group_factory.hpp" |
---|
12 | #include "declare_group.hpp" |
---|
13 | |
---|
14 | namespace xios { |
---|
15 | |
---|
16 | /// ////////////////////// Déclarations ////////////////////// /// |
---|
17 | class CTransformationGroup; |
---|
18 | class CTransformationAttributes; |
---|
19 | class CTransformation; |
---|
20 | ///-------------------------------------------------------------- |
---|
21 | |
---|
22 | // Declare/Define CFileAttribute |
---|
23 | BEGIN_DECLARE_ATTRIBUTE_MAP(CTransformation) |
---|
24 | #include "transformation_attribute.conf" |
---|
25 | END_DECLARE_ATTRIBUTE_MAP(CTransformation) |
---|
26 | |
---|
27 | ///-------------------------------------------------------------- |
---|
28 | /*! |
---|
29 | \class CTransformation |
---|
30 | This class describes transformation in xml file. |
---|
31 | */ |
---|
32 | class CTransformation |
---|
33 | : public CObjectTemplate<CTransformation> |
---|
34 | , public CTransformationAttributes |
---|
35 | { |
---|
36 | public : |
---|
37 | enum TransformationId |
---|
38 | { |
---|
39 | TRANS_ID_ZOOM, TRANS_ID_INVERSE |
---|
40 | }; |
---|
41 | typedef CObjectTemplate<CTransformation> SuperClass; |
---|
42 | typedef CTransformationAttributes SuperClassAttribute; |
---|
43 | |
---|
44 | public : |
---|
45 | /// Constructeurs /// |
---|
46 | CTransformation(void); |
---|
47 | explicit CTransformation(const StdString& id); |
---|
48 | |
---|
49 | /// Destructeur /// |
---|
50 | virtual ~CTransformation(void); |
---|
51 | |
---|
52 | /// Accesseurs statiques /// |
---|
53 | static StdString GetName(void); |
---|
54 | static StdString GetDefName(void); |
---|
55 | static ENodeType GetType(void); |
---|
56 | private: |
---|
57 | static std::vector<StdString> TransformationTypes; |
---|
58 | static std::vector<TransformationId> TransformationTypeIds; |
---|
59 | |
---|
60 | public : |
---|
61 | void checkAttributes(); |
---|
62 | |
---|
63 | private: |
---|
64 | void checkAttributesType(TransformationId& transType); |
---|
65 | void checkAttributesZoomType(); |
---|
66 | void checkAttributesInverseType(); |
---|
67 | |
---|
68 | private: |
---|
69 | }; // class CTransformation |
---|
70 | |
---|
71 | DECLARE_GROUP(CTransformation); |
---|
72 | } // namespace xios |
---|
73 | |
---|
74 | #endif // __XMLIO_CTransformation__ |
---|