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 "axis.hpp" |
---|
14 | |
---|
15 | extern "C" |
---|
16 | { |
---|
17 | typedef xios::CAxisGroup* axisgroup_Ptr; |
---|
18 | |
---|
19 | void cxios_set_axisgroup_group_ref(axisgroup_Ptr axisgroup_hdl, const char * group_ref, int group_ref_size) |
---|
20 | { |
---|
21 | std::string group_ref_str; |
---|
22 | if(!cstr2string(group_ref, group_ref_size, group_ref_str)) return; |
---|
23 | CTimer::get("XIOS").resume(); |
---|
24 | axisgroup_hdl->group_ref.setValue(group_ref_str); |
---|
25 | axisgroup_hdl->sendAttributToServer(axisgroup_hdl->group_ref); |
---|
26 | CTimer::get("XIOS").suspend(); |
---|
27 | } |
---|
28 | |
---|
29 | void cxios_get_axisgroup_group_ref(axisgroup_Ptr axisgroup_hdl, char * group_ref, int group_ref_size) |
---|
30 | { |
---|
31 | CTimer::get("XIOS").resume(); |
---|
32 | if(!string_copy(axisgroup_hdl->group_ref.getValue(),group_ref , group_ref_size)) |
---|
33 | ERROR("void cxios_get_axisgroup_group_ref(axisgroup_Ptr axisgroup_hdl, char * group_ref, int group_ref_size)", <<"Input string is to short"); |
---|
34 | CTimer::get("XIOS").suspend(); |
---|
35 | } |
---|
36 | |
---|
37 | |
---|
38 | void cxios_set_axisgroup_long_name(axisgroup_Ptr axisgroup_hdl, const char * long_name, int long_name_size) |
---|
39 | { |
---|
40 | std::string long_name_str; |
---|
41 | if(!cstr2string(long_name, long_name_size, long_name_str)) return; |
---|
42 | CTimer::get("XIOS").resume(); |
---|
43 | axisgroup_hdl->long_name.setValue(long_name_str); |
---|
44 | axisgroup_hdl->sendAttributToServer(axisgroup_hdl->long_name); |
---|
45 | CTimer::get("XIOS").suspend(); |
---|
46 | } |
---|
47 | |
---|
48 | void cxios_get_axisgroup_long_name(axisgroup_Ptr axisgroup_hdl, char * long_name, int long_name_size) |
---|
49 | { |
---|
50 | CTimer::get("XIOS").resume(); |
---|
51 | if(!string_copy(axisgroup_hdl->long_name.getValue(),long_name , long_name_size)) |
---|
52 | ERROR("void cxios_get_axisgroup_long_name(axisgroup_Ptr axisgroup_hdl, char * long_name, int long_name_size)", <<"Input string is to short"); |
---|
53 | CTimer::get("XIOS").suspend(); |
---|
54 | } |
---|
55 | |
---|
56 | |
---|
57 | void cxios_set_axisgroup_name(axisgroup_Ptr axisgroup_hdl, const char * name, int name_size) |
---|
58 | { |
---|
59 | std::string name_str; |
---|
60 | if(!cstr2string(name, name_size, name_str)) return; |
---|
61 | CTimer::get("XIOS").resume(); |
---|
62 | axisgroup_hdl->name.setValue(name_str); |
---|
63 | axisgroup_hdl->sendAttributToServer(axisgroup_hdl->name); |
---|
64 | CTimer::get("XIOS").suspend(); |
---|
65 | } |
---|
66 | |
---|
67 | void cxios_get_axisgroup_name(axisgroup_Ptr axisgroup_hdl, char * name, int name_size) |
---|
68 | { |
---|
69 | CTimer::get("XIOS").resume(); |
---|
70 | if(!string_copy(axisgroup_hdl->name.getValue(),name , name_size)) |
---|
71 | ERROR("void cxios_get_axisgroup_name(axisgroup_Ptr axisgroup_hdl, char * name, int name_size)", <<"Input string is to short"); |
---|
72 | CTimer::get("XIOS").suspend(); |
---|
73 | } |
---|
74 | |
---|
75 | |
---|
76 | void cxios_set_axisgroup_size(axisgroup_Ptr axisgroup_hdl, int size) |
---|
77 | { |
---|
78 | CTimer::get("XIOS").resume(); |
---|
79 | axisgroup_hdl->size.setValue(size); |
---|
80 | axisgroup_hdl->sendAttributToServer(axisgroup_hdl->size); |
---|
81 | CTimer::get("XIOS").suspend(); |
---|
82 | } |
---|
83 | |
---|
84 | void cxios_get_axisgroup_size(axisgroup_Ptr axisgroup_hdl, int* size) |
---|
85 | { |
---|
86 | *size = axisgroup_hdl->size.getValue(); |
---|
87 | } |
---|
88 | |
---|
89 | |
---|
90 | void cxios_set_axisgroup_standard_name(axisgroup_Ptr axisgroup_hdl, const char * standard_name, int standard_name_size) |
---|
91 | { |
---|
92 | std::string standard_name_str; |
---|
93 | if(!cstr2string(standard_name, standard_name_size, standard_name_str)) return; |
---|
94 | CTimer::get("XIOS").resume(); |
---|
95 | axisgroup_hdl->standard_name.setValue(standard_name_str); |
---|
96 | axisgroup_hdl->sendAttributToServer(axisgroup_hdl->standard_name); |
---|
97 | CTimer::get("XIOS").suspend(); |
---|
98 | } |
---|
99 | |
---|
100 | void cxios_get_axisgroup_standard_name(axisgroup_Ptr axisgroup_hdl, char * standard_name, int standard_name_size) |
---|
101 | { |
---|
102 | CTimer::get("XIOS").resume(); |
---|
103 | if(!string_copy(axisgroup_hdl->standard_name.getValue(),standard_name , standard_name_size)) |
---|
104 | ERROR("void cxios_get_axisgroup_standard_name(axisgroup_Ptr axisgroup_hdl, char * standard_name, int standard_name_size)", <<"Input string is to short"); |
---|
105 | CTimer::get("XIOS").suspend(); |
---|
106 | } |
---|
107 | |
---|
108 | |
---|
109 | void cxios_set_axisgroup_unit(axisgroup_Ptr axisgroup_hdl, const char * unit, int unit_size) |
---|
110 | { |
---|
111 | std::string unit_str; |
---|
112 | if(!cstr2string(unit, unit_size, unit_str)) return; |
---|
113 | CTimer::get("XIOS").resume(); |
---|
114 | axisgroup_hdl->unit.setValue(unit_str); |
---|
115 | axisgroup_hdl->sendAttributToServer(axisgroup_hdl->unit); |
---|
116 | CTimer::get("XIOS").suspend(); |
---|
117 | } |
---|
118 | |
---|
119 | void cxios_get_axisgroup_unit(axisgroup_Ptr axisgroup_hdl, char * unit, int unit_size) |
---|
120 | { |
---|
121 | CTimer::get("XIOS").resume(); |
---|
122 | if(!string_copy(axisgroup_hdl->unit.getValue(),unit , unit_size)) |
---|
123 | ERROR("void cxios_get_axisgroup_unit(axisgroup_Ptr axisgroup_hdl, char * unit, int unit_size)", <<"Input string is to short"); |
---|
124 | CTimer::get("XIOS").suspend(); |
---|
125 | } |
---|
126 | |
---|
127 | |
---|
128 | void cxios_set_axisgroup_value(axisgroup_Ptr axisgroup_hdl, double* value, int extent1) |
---|
129 | { |
---|
130 | CTimer::get("XIOS").resume(); |
---|
131 | ARRAY(double,1) array_tmp(new CArray<double,1>(boost::extents[extent1])); |
---|
132 | std::copy(value, &(value[array_tmp->num_elements()]), array_tmp->data()); |
---|
133 | axisgroup_hdl->value.setValue(array_tmp); |
---|
134 | axisgroup_hdl->sendAttributToServer(axisgroup_hdl->value); |
---|
135 | } |
---|
136 | |
---|
137 | void cxios_get_axisgroup_value(axisgroup_Ptr axisgroup_hdl, double* value, int extent1) |
---|
138 | { |
---|
139 | if (!array_copy(axisgroup_hdl->value.getValue(), value, extent1)) |
---|
140 | ERROR("void cxios_set_axisgroup_value(axisgroup_Ptr axisgroup_hdl, double* value, int extent1)",<<"Output array size is not conform to array size attribute") ; |
---|
141 | CTimer::get("XIOS").suspend(); |
---|
142 | } |
---|
143 | |
---|
144 | |
---|
145 | |
---|
146 | } |
---|