source: XIOS/trunk/src/interface/c_attr/icfilegroup_attr.cpp @ 445

Last change on this file since 445 was 445, checked in by ymipsl, 11 years ago

Add possibility to make inheritance of attributes and reference before closing the context definition.
New fortran fonction : xios_solve inheritance()
After this call, the value of attribute have the inherited value of their parent.

YM

  • Property svn:eol-style set to native
File size: 13.0 KB
Line 
1/* ************************************************************************** *
2 *               Interface auto generated - do not modify                   *
3 * ************************************************************************** */
4
5#include <boost/multi_array.hpp>
6#include <boost/shared_ptr.hpp>
7#include "xmlioserver.hpp"
8#include "attribute_template.hpp"
9#include "object_template.hpp"
10#include "group_template.hpp"
11#include "icutil.hpp"
12#include "timer.hpp"
13#include "node_type.hpp"
14
15extern "C"
16{
17  typedef xios::CFileGroup*  filegroup_Ptr;
18 
19  void cxios_set_filegroup_description(filegroup_Ptr filegroup_hdl, const char * description, int description_size)
20  {
21    std::string description_str;
22    if(!cstr2string(description, description_size, description_str)) return;
23     CTimer::get("XIOS").resume();
24    filegroup_hdl->description.setValue(description_str);
25    filegroup_hdl->sendAttributToServer(filegroup_hdl->description);
26     CTimer::get("XIOS").suspend();
27  }
28 
29  void cxios_get_filegroup_description(filegroup_Ptr filegroup_hdl, char * description, int description_size)
30  {
31     CTimer::get("XIOS").resume();
32    if(!string_copy(filegroup_hdl->description.getInheritedValue(),description , description_size))
33      ERROR("void cxios_get_filegroup_description(filegroup_Ptr filegroup_hdl, char * description, int description_size)", <<"Input string is to short");
34     CTimer::get("XIOS").suspend();
35  }
36 
37  bool cxios_is_defined_filegroup_description(filegroup_Ptr filegroup_hdl )
38  {
39     CTimer::get("XIOS").resume();
40    return filegroup_hdl->description.hasInheritedValue();
41     CTimer::get("XIOS").suspend();
42  }
43 
44 
45 
46  void cxios_set_filegroup_enabled(filegroup_Ptr filegroup_hdl, bool enabled)
47  {
48     CTimer::get("XIOS").resume();
49    filegroup_hdl->enabled.setValue(enabled);
50    filegroup_hdl->sendAttributToServer(filegroup_hdl->enabled);
51     CTimer::get("XIOS").suspend();
52  }
53 
54  void cxios_get_filegroup_enabled(filegroup_Ptr filegroup_hdl, bool* enabled)
55  {
56    *enabled = filegroup_hdl->enabled.getInheritedValue();
57  }
58 
59  bool cxios_is_defined_filegroup_enabled(filegroup_Ptr filegroup_hdl )
60  {
61     CTimer::get("XIOS").resume();
62    return filegroup_hdl->enabled.hasInheritedValue();
63     CTimer::get("XIOS").suspend();
64  }
65 
66 
67 
68  void cxios_set_filegroup_group_ref(filegroup_Ptr filegroup_hdl, const char * group_ref, int group_ref_size)
69  {
70    std::string group_ref_str;
71    if(!cstr2string(group_ref, group_ref_size, group_ref_str)) return;
72     CTimer::get("XIOS").resume();
73    filegroup_hdl->group_ref.setValue(group_ref_str);
74    filegroup_hdl->sendAttributToServer(filegroup_hdl->group_ref);
75     CTimer::get("XIOS").suspend();
76  }
77 
78  void cxios_get_filegroup_group_ref(filegroup_Ptr filegroup_hdl, char * group_ref, int group_ref_size)
79  {
80     CTimer::get("XIOS").resume();
81    if(!string_copy(filegroup_hdl->group_ref.getInheritedValue(),group_ref , group_ref_size))
82      ERROR("void cxios_get_filegroup_group_ref(filegroup_Ptr filegroup_hdl, char * group_ref, int group_ref_size)", <<"Input string is to short");
83     CTimer::get("XIOS").suspend();
84  }
85 
86  bool cxios_is_defined_filegroup_group_ref(filegroup_Ptr filegroup_hdl )
87  {
88     CTimer::get("XIOS").resume();
89    return filegroup_hdl->group_ref.hasInheritedValue();
90     CTimer::get("XIOS").suspend();
91  }
92 
93 
94 
95  void cxios_set_filegroup_min_digits(filegroup_Ptr filegroup_hdl, int min_digits)
96  {
97     CTimer::get("XIOS").resume();
98    filegroup_hdl->min_digits.setValue(min_digits);
99    filegroup_hdl->sendAttributToServer(filegroup_hdl->min_digits);
100     CTimer::get("XIOS").suspend();
101  }
102 
103  void cxios_get_filegroup_min_digits(filegroup_Ptr filegroup_hdl, int* min_digits)
104  {
105    *min_digits = filegroup_hdl->min_digits.getInheritedValue();
106  }
107 
108  bool cxios_is_defined_filegroup_min_digits(filegroup_Ptr filegroup_hdl )
109  {
110     CTimer::get("XIOS").resume();
111    return filegroup_hdl->min_digits.hasInheritedValue();
112     CTimer::get("XIOS").suspend();
113  }
114 
115 
116 
117  void cxios_set_filegroup_name(filegroup_Ptr filegroup_hdl, const char * name, int name_size)
118  {
119    std::string name_str;
120    if(!cstr2string(name, name_size, name_str)) return;
121     CTimer::get("XIOS").resume();
122    filegroup_hdl->name.setValue(name_str);
123    filegroup_hdl->sendAttributToServer(filegroup_hdl->name);
124     CTimer::get("XIOS").suspend();
125  }
126 
127  void cxios_get_filegroup_name(filegroup_Ptr filegroup_hdl, char * name, int name_size)
128  {
129     CTimer::get("XIOS").resume();
130    if(!string_copy(filegroup_hdl->name.getInheritedValue(),name , name_size))
131      ERROR("void cxios_get_filegroup_name(filegroup_Ptr filegroup_hdl, char * name, int name_size)", <<"Input string is to short");
132     CTimer::get("XIOS").suspend();
133  }
134 
135  bool cxios_is_defined_filegroup_name(filegroup_Ptr filegroup_hdl )
136  {
137     CTimer::get("XIOS").resume();
138    return filegroup_hdl->name.hasInheritedValue();
139     CTimer::get("XIOS").suspend();
140  }
141 
142 
143 
144  void cxios_set_filegroup_name_suffix(filegroup_Ptr filegroup_hdl, const char * name_suffix, int name_suffix_size)
145  {
146    std::string name_suffix_str;
147    if(!cstr2string(name_suffix, name_suffix_size, name_suffix_str)) return;
148     CTimer::get("XIOS").resume();
149    filegroup_hdl->name_suffix.setValue(name_suffix_str);
150    filegroup_hdl->sendAttributToServer(filegroup_hdl->name_suffix);
151     CTimer::get("XIOS").suspend();
152  }
153 
154  void cxios_get_filegroup_name_suffix(filegroup_Ptr filegroup_hdl, char * name_suffix, int name_suffix_size)
155  {
156     CTimer::get("XIOS").resume();
157    if(!string_copy(filegroup_hdl->name_suffix.getInheritedValue(),name_suffix , name_suffix_size))
158      ERROR("void cxios_get_filegroup_name_suffix(filegroup_Ptr filegroup_hdl, char * name_suffix, int name_suffix_size)", <<"Input string is to short");
159     CTimer::get("XIOS").suspend();
160  }
161 
162  bool cxios_is_defined_filegroup_name_suffix(filegroup_Ptr filegroup_hdl )
163  {
164     CTimer::get("XIOS").resume();
165    return filegroup_hdl->name_suffix.hasInheritedValue();
166     CTimer::get("XIOS").suspend();
167  }
168 
169 
170 
171  void cxios_set_filegroup_output_freq(filegroup_Ptr filegroup_hdl, const char * output_freq, int output_freq_size)
172  {
173    std::string output_freq_str;
174    if(!cstr2string(output_freq, output_freq_size, output_freq_str)) return;
175     CTimer::get("XIOS").resume();
176    filegroup_hdl->output_freq.setValue(output_freq_str);
177    filegroup_hdl->sendAttributToServer(filegroup_hdl->output_freq);
178     CTimer::get("XIOS").suspend();
179  }
180 
181  void cxios_get_filegroup_output_freq(filegroup_Ptr filegroup_hdl, char * output_freq, int output_freq_size)
182  {
183     CTimer::get("XIOS").resume();
184    if(!string_copy(filegroup_hdl->output_freq.getInheritedValue(),output_freq , output_freq_size))
185      ERROR("void cxios_get_filegroup_output_freq(filegroup_Ptr filegroup_hdl, char * output_freq, int output_freq_size)", <<"Input string is to short");
186     CTimer::get("XIOS").suspend();
187  }
188 
189  bool cxios_is_defined_filegroup_output_freq(filegroup_Ptr filegroup_hdl )
190  {
191     CTimer::get("XIOS").resume();
192    return filegroup_hdl->output_freq.hasInheritedValue();
193     CTimer::get("XIOS").suspend();
194  }
195 
196 
197 
198  void cxios_set_filegroup_output_level(filegroup_Ptr filegroup_hdl, int output_level)
199  {
200     CTimer::get("XIOS").resume();
201    filegroup_hdl->output_level.setValue(output_level);
202    filegroup_hdl->sendAttributToServer(filegroup_hdl->output_level);
203     CTimer::get("XIOS").suspend();
204  }
205 
206  void cxios_get_filegroup_output_level(filegroup_Ptr filegroup_hdl, int* output_level)
207  {
208    *output_level = filegroup_hdl->output_level.getInheritedValue();
209  }
210 
211  bool cxios_is_defined_filegroup_output_level(filegroup_Ptr filegroup_hdl )
212  {
213     CTimer::get("XIOS").resume();
214    return filegroup_hdl->output_level.hasInheritedValue();
215     CTimer::get("XIOS").suspend();
216  }
217 
218 
219 
220  void cxios_set_filegroup_par_access(filegroup_Ptr filegroup_hdl, const char * par_access, int par_access_size)
221  {
222    std::string par_access_str;
223    if(!cstr2string(par_access, par_access_size, par_access_str)) return;
224     CTimer::get("XIOS").resume();
225    filegroup_hdl->par_access.setValue(par_access_str);
226    filegroup_hdl->sendAttributToServer(filegroup_hdl->par_access);
227     CTimer::get("XIOS").suspend();
228  }
229 
230  void cxios_get_filegroup_par_access(filegroup_Ptr filegroup_hdl, char * par_access, int par_access_size)
231  {
232     CTimer::get("XIOS").resume();
233    if(!string_copy(filegroup_hdl->par_access.getInheritedValue(),par_access , par_access_size))
234      ERROR("void cxios_get_filegroup_par_access(filegroup_Ptr filegroup_hdl, char * par_access, int par_access_size)", <<"Input string is to short");
235     CTimer::get("XIOS").suspend();
236  }
237 
238  bool cxios_is_defined_filegroup_par_access(filegroup_Ptr filegroup_hdl )
239  {
240     CTimer::get("XIOS").resume();
241    return filegroup_hdl->par_access.hasInheritedValue();
242     CTimer::get("XIOS").suspend();
243  }
244 
245 
246 
247  void cxios_set_filegroup_split_freq(filegroup_Ptr filegroup_hdl, const char * split_freq, int split_freq_size)
248  {
249    std::string split_freq_str;
250    if(!cstr2string(split_freq, split_freq_size, split_freq_str)) return;
251     CTimer::get("XIOS").resume();
252    filegroup_hdl->split_freq.setValue(split_freq_str);
253    filegroup_hdl->sendAttributToServer(filegroup_hdl->split_freq);
254     CTimer::get("XIOS").suspend();
255  }
256 
257  void cxios_get_filegroup_split_freq(filegroup_Ptr filegroup_hdl, char * split_freq, int split_freq_size)
258  {
259     CTimer::get("XIOS").resume();
260    if(!string_copy(filegroup_hdl->split_freq.getInheritedValue(),split_freq , split_freq_size))
261      ERROR("void cxios_get_filegroup_split_freq(filegroup_Ptr filegroup_hdl, char * split_freq, int split_freq_size)", <<"Input string is to short");
262     CTimer::get("XIOS").suspend();
263  }
264 
265  bool cxios_is_defined_filegroup_split_freq(filegroup_Ptr filegroup_hdl )
266  {
267     CTimer::get("XIOS").resume();
268    return filegroup_hdl->split_freq.hasInheritedValue();
269     CTimer::get("XIOS").suspend();
270  }
271 
272 
273 
274  void cxios_set_filegroup_split_freq_format(filegroup_Ptr filegroup_hdl, const char * split_freq_format, int split_freq_format_size)
275  {
276    std::string split_freq_format_str;
277    if(!cstr2string(split_freq_format, split_freq_format_size, split_freq_format_str)) return;
278     CTimer::get("XIOS").resume();
279    filegroup_hdl->split_freq_format.setValue(split_freq_format_str);
280    filegroup_hdl->sendAttributToServer(filegroup_hdl->split_freq_format);
281     CTimer::get("XIOS").suspend();
282  }
283 
284  void cxios_get_filegroup_split_freq_format(filegroup_Ptr filegroup_hdl, char * split_freq_format, int split_freq_format_size)
285  {
286     CTimer::get("XIOS").resume();
287    if(!string_copy(filegroup_hdl->split_freq_format.getInheritedValue(),split_freq_format , split_freq_format_size))
288      ERROR("void cxios_get_filegroup_split_freq_format(filegroup_Ptr filegroup_hdl, char * split_freq_format, int split_freq_format_size)", <<"Input string is to short");
289     CTimer::get("XIOS").suspend();
290  }
291 
292  bool cxios_is_defined_filegroup_split_freq_format(filegroup_Ptr filegroup_hdl )
293  {
294     CTimer::get("XIOS").resume();
295    return filegroup_hdl->split_freq_format.hasInheritedValue();
296     CTimer::get("XIOS").suspend();
297  }
298 
299 
300 
301  void cxios_set_filegroup_sync_freq(filegroup_Ptr filegroup_hdl, const char * sync_freq, int sync_freq_size)
302  {
303    std::string sync_freq_str;
304    if(!cstr2string(sync_freq, sync_freq_size, sync_freq_str)) return;
305     CTimer::get("XIOS").resume();
306    filegroup_hdl->sync_freq.setValue(sync_freq_str);
307    filegroup_hdl->sendAttributToServer(filegroup_hdl->sync_freq);
308     CTimer::get("XIOS").suspend();
309  }
310 
311  void cxios_get_filegroup_sync_freq(filegroup_Ptr filegroup_hdl, char * sync_freq, int sync_freq_size)
312  {
313     CTimer::get("XIOS").resume();
314    if(!string_copy(filegroup_hdl->sync_freq.getInheritedValue(),sync_freq , sync_freq_size))
315      ERROR("void cxios_get_filegroup_sync_freq(filegroup_Ptr filegroup_hdl, char * sync_freq, int sync_freq_size)", <<"Input string is to short");
316     CTimer::get("XIOS").suspend();
317  }
318 
319  bool cxios_is_defined_filegroup_sync_freq(filegroup_Ptr filegroup_hdl )
320  {
321     CTimer::get("XIOS").resume();
322    return filegroup_hdl->sync_freq.hasInheritedValue();
323     CTimer::get("XIOS").suspend();
324  }
325 
326 
327 
328  void cxios_set_filegroup_type(filegroup_Ptr filegroup_hdl, const char * type, int type_size)
329  {
330    std::string type_str;
331    if(!cstr2string(type, type_size, type_str)) return;
332     CTimer::get("XIOS").resume();
333    filegroup_hdl->type.fromString(type_str);
334    filegroup_hdl->sendAttributToServer(filegroup_hdl->type);
335     CTimer::get("XIOS").suspend();
336  }
337 
338  void cxios_get_filegroup_type(filegroup_Ptr filegroup_hdl, char * type, int type_size)
339  {
340     CTimer::get("XIOS").resume();
341    if(!string_copy(filegroup_hdl->type.getInheritedStringValue(),type , type_size))
342      ERROR("void cxios_get_filegroup_type(filegroup_Ptr filegroup_hdl, char * type, int type_size)", <<"Input string is to short");
343     CTimer::get("XIOS").suspend();
344  }
345 
346  bool cxios_is_defined_filegroup_type(filegroup_Ptr filegroup_hdl )
347  {
348     CTimer::get("XIOS").resume();
349    return filegroup_hdl->type.hasInheritedValue();
350     CTimer::get("XIOS").suspend();
351  }
352 
353 
354 
355 
356}
Note: See TracBrowser for help on using the repository browser.