Salome HOME
ENV: Windows porting.
[modules/kernel.git] / src / SALOMEDS / SALOMEDS_ClientAttributes.hxx
1 //  File   : SALOMEDS_Attributes.hxx
2 //  Author : Sergey RUIN
3 //  Module : SALOME
4
5 #ifndef __SALOMEDSCLIENT_ATTRIBUTES__H__
6 #define __SALOMEDSCLIENT_ATTRIBUTES__H__
7
8 #include CORBA_SERVER_HEADER(SALOMEDS_Attributes)
9
10 #include "SALOMEDSImpl_GenericAttribute.hxx"
11 #include "SALOMEDSImpl_AttributeName.hxx"
12 #include "SALOMEDSImpl_AttributeComment.hxx"
13 #include "SALOMEDSImpl_AttributeInteger.hxx"
14 #include "SALOMEDSImpl_AttributeReal.hxx"
15 #include "SALOMEDSImpl_AttributeTreeNode.hxx"
16 #include "SALOMEDSImpl_AttributeUserID.hxx"
17 #include "SALOMEDSImpl_AttributeSequenceOfReal.hxx"
18 #include "SALOMEDSImpl_AttributeSequenceOfInteger.hxx" 
19 #include "SALOMEDSImpl_AttributeIOR.hxx"
20 #include "SALOMEDSImpl_AttributePersistentRef.hxx" 
21 #include "SALOMEDSImpl_AttributeDrawable.hxx"
22 #include "SALOMEDSImpl_AttributeSelectable.hxx"
23 #include "SALOMEDSImpl_AttributeExpandable.hxx"
24 #include "SALOMEDSImpl_AttributeOpened.hxx"
25 #include "SALOMEDSImpl_AttributeTextColor.hxx"
26 #include "SALOMEDSImpl_AttributeTextHighlightColor.hxx"
27 #include "SALOMEDSImpl_AttributePixMap.hxx"
28 #include "SALOMEDSImpl_AttributeLocalID.hxx"
29 #include "SALOMEDSImpl_AttributeTarget.hxx"
30 #include "SALOMEDSImpl_AttributeTableOfInteger.hxx"
31 #include "SALOMEDSImpl_AttributeTableOfReal.hxx"
32 #include "SALOMEDSImpl_AttributeTableOfString.hxx"
33 #include "SALOMEDSImpl_AttributeStudyProperties.hxx"
34 #include "SALOMEDSImpl_AttributePythonObject.hxx"
35 #include "SALOMEDSImpl_AttributeExternalFileDef.hxx"
36 #include "SALOMEDSImpl_AttributeFileType.hxx"
37 #include "SALOMEDSImpl_AttributeFlags.hxx"
38 #include "SALOMEDSImpl_AttributeGraphic.hxx"
39
40 #include "SALOMEDS_GenericAttribute.hxx"
41 #include "SALOMEDS_AttributeName.hxx"
42 #include "SALOMEDS_AttributeComment.hxx"
43 #include "SALOMEDS_AttributeInteger.hxx"
44 #include "SALOMEDS_AttributeReal.hxx"
45 #include "SALOMEDS_AttributeTreeNode.hxx"
46 #include "SALOMEDS_AttributeUserID.hxx"
47 #include "SALOMEDS_AttributeSequenceOfReal.hxx"
48 #include "SALOMEDS_AttributeSequenceOfInteger.hxx" 
49 #include "SALOMEDS_AttributeIOR.hxx"
50 #include "SALOMEDS_AttributePersistentRef.hxx" 
51 #include "SALOMEDS_AttributeDrawable.hxx"
52 #include "SALOMEDS_AttributeSelectable.hxx"
53 #include "SALOMEDS_AttributeExpandable.hxx"
54 #include "SALOMEDS_AttributeOpened.hxx"
55 #include "SALOMEDS_AttributeTextColor.hxx"
56 #include "SALOMEDS_AttributeTextHighlightColor.hxx"
57 #include "SALOMEDS_AttributePixMap.hxx"
58 #include "SALOMEDS_AttributeLocalID.hxx"
59 #include "SALOMEDS_AttributeTarget.hxx"
60 #include "SALOMEDS_AttributeTableOfInteger.hxx"
61 #include "SALOMEDS_AttributeTableOfReal.hxx"
62 #include "SALOMEDS_AttributeTableOfString.hxx"
63 #include "SALOMEDS_AttributeStudyProperties.hxx"
64 #include "SALOMEDS_AttributePythonObject.hxx"
65 #include "SALOMEDS_AttributeExternalFileDef.hxx"
66 #include "SALOMEDS_AttributeFileType.hxx"
67 #include "SALOMEDS_AttributeFlags.hxx"
68 #include "SALOMEDS_AttributeGraphic.hxx"
69
70 #define __CreateClientAttributeLocal(CORBA_Name) if (strcmp(aTypeOfAttribute.c_str(), #CORBA_Name) == 0) { \
71     Handle(SALOMEDSImpl_##CORBA_Name) A = Handle(SALOMEDSImpl_##CORBA_Name)::DownCast(theGA); \
72     aGA = new SALOMEDS_##CORBA_Name(A); \
73   }
74
75 #define __CreateClientAttributeCORBA(CORBA_Name) if (strcmp(aTypeOfAttribute.c_str(), #CORBA_Name) == 0) { \
76     SALOMEDS::CORBA_Name##_var A = SALOMEDS::CORBA_Name::_narrow(theGA); \
77     aGA = new SALOMEDS_##CORBA_Name(A); \
78   }
79
80 #define __CreateGenericClientAttributeLocal \
81 __CreateClientAttributeLocal(AttributeReal) \
82 __CreateClientAttributeLocal(AttributeInteger) \
83 __CreateClientAttributeLocal(AttributeSequenceOfReal) \
84 __CreateClientAttributeLocal(AttributeSequenceOfInteger) \
85 __CreateClientAttributeLocal(AttributeName) \
86 __CreateClientAttributeLocal(AttributeComment) \
87 __CreateClientAttributeLocal(AttributeIOR) \
88 __CreateClientAttributeLocal(AttributePixMap) \
89 __CreateClientAttributeLocal(AttributeLocalID) \
90 __CreateClientAttributeLocal(AttributeTableOfInteger) \
91 __CreateClientAttributeLocal(AttributeTableOfReal) \
92 __CreateClientAttributeLocal(AttributeTableOfString) \
93 __CreateClientAttributeLocal(AttributePythonObject) \
94 __CreateClientAttributeLocal(AttributePersistentRef) \
95 __CreateClientAttributeLocal(AttributeDrawable) \
96 __CreateClientAttributeLocal(AttributeSelectable) \
97 __CreateClientAttributeLocal(AttributeExpandable) \
98 __CreateClientAttributeLocal(AttributeOpened) \
99 __CreateClientAttributeLocal(AttributeTextColor) \
100 __CreateClientAttributeLocal(AttributeTextHighlightColor) \
101 __CreateClientAttributeLocal(AttributeTarget) \
102 __CreateClientAttributeLocal(AttributeStudyProperties) \
103 __CreateClientAttributeLocal(AttributeExternalFileDef) \
104 __CreateClientAttributeLocal(AttributeFileType) \
105 __CreateClientAttributeLocal(AttributeFlags) \
106 __CreateClientAttributeLocal(AttributeGraphic) \
107 __CreateClientAttributeLocal(AttributeTreeNode) \
108 __CreateClientAttributeLocal(AttributeUserID)
109
110 #define __CreateGenericClientAttributeCORBA \
111 __CreateClientAttributeCORBA(AttributeReal) \
112 __CreateClientAttributeCORBA(AttributeInteger) \
113 __CreateClientAttributeCORBA(AttributeSequenceOfReal) \
114 __CreateClientAttributeCORBA(AttributeSequenceOfInteger) \
115 __CreateClientAttributeCORBA(AttributeName) \
116 __CreateClientAttributeCORBA(AttributeComment) \
117 __CreateClientAttributeCORBA(AttributeIOR) \
118 __CreateClientAttributeCORBA(AttributePixMap) \
119 __CreateClientAttributeCORBA(AttributeLocalID) \
120 __CreateClientAttributeCORBA(AttributeTableOfInteger) \
121 __CreateClientAttributeCORBA(AttributeTableOfReal) \
122 __CreateClientAttributeCORBA(AttributeTableOfString) \
123 __CreateClientAttributeCORBA(AttributePythonObject) \
124 __CreateClientAttributeCORBA(AttributePersistentRef) \
125 __CreateClientAttributeCORBA(AttributeDrawable) \
126 __CreateClientAttributeCORBA(AttributeSelectable) \
127 __CreateClientAttributeCORBA(AttributeExpandable) \
128 __CreateClientAttributeCORBA(AttributeOpened) \
129 __CreateClientAttributeCORBA(AttributeTextColor) \
130 __CreateClientAttributeCORBA(AttributeTextHighlightColor) \
131 __CreateClientAttributeCORBA(AttributeTarget) \
132 __CreateClientAttributeCORBA(AttributeStudyProperties) \
133 __CreateClientAttributeCORBA(AttributeExternalFileDef) \
134 __CreateClientAttributeCORBA(AttributeFileType) \
135 __CreateClientAttributeCORBA(AttributeFlags) \
136 __CreateClientAttributeCORBA(AttributeGraphic) \
137 __CreateClientAttributeCORBA(AttributeTreeNode) \
138 __CreateClientAttributeCORBA(AttributeUserID)
139
140 #endif