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 "icdate.hpp" |
---|
13 | #include "timer.hpp" |
---|
14 | #include "node_type.hpp" |
---|
15 | |
---|
16 | extern "C" |
---|
17 | { |
---|
18 | typedef xios::CCalendarWrapper* calendar_wrapper_Ptr; |
---|
19 | |
---|
20 | void cxios_set_calendar_wrapper_start_date(calendar_wrapper_Ptr calendar_wrapper_hdl, const char * start_date, int start_date_size) |
---|
21 | { |
---|
22 | std::string start_date_str; |
---|
23 | if(!cstr2string(start_date, start_date_size, start_date_str)) return; |
---|
24 | CTimer::get("XIOS").resume(); |
---|
25 | calendar_wrapper_hdl->start_date.setValue(start_date_str); |
---|
26 | CTimer::get("XIOS").suspend(); |
---|
27 | } |
---|
28 | |
---|
29 | void cxios_get_calendar_wrapper_start_date(calendar_wrapper_Ptr calendar_wrapper_hdl, char * start_date, int start_date_size) |
---|
30 | { |
---|
31 | CTimer::get("XIOS").resume(); |
---|
32 | if(!string_copy(calendar_wrapper_hdl->start_date.getInheritedValue(),start_date , start_date_size)) |
---|
33 | ERROR("void cxios_get_calendar_wrapper_start_date(calendar_wrapper_Ptr calendar_wrapper_hdl, char * start_date, int start_date_size)", <<"Input string is to short"); |
---|
34 | CTimer::get("XIOS").suspend(); |
---|
35 | } |
---|
36 | |
---|
37 | bool cxios_is_defined_calendar_wrapper_start_date(calendar_wrapper_Ptr calendar_wrapper_hdl ) |
---|
38 | { |
---|
39 | CTimer::get("XIOS").resume(); |
---|
40 | return calendar_wrapper_hdl->start_date.hasInheritedValue(); |
---|
41 | CTimer::get("XIOS").suspend(); |
---|
42 | } |
---|
43 | |
---|
44 | |
---|
45 | |
---|
46 | void cxios_set_calendar_wrapper_time_origin(calendar_wrapper_Ptr calendar_wrapper_hdl, const char * time_origin, int time_origin_size) |
---|
47 | { |
---|
48 | std::string time_origin_str; |
---|
49 | if(!cstr2string(time_origin, time_origin_size, time_origin_str)) return; |
---|
50 | CTimer::get("XIOS").resume(); |
---|
51 | calendar_wrapper_hdl->time_origin.setValue(time_origin_str); |
---|
52 | CTimer::get("XIOS").suspend(); |
---|
53 | } |
---|
54 | |
---|
55 | void cxios_get_calendar_wrapper_time_origin(calendar_wrapper_Ptr calendar_wrapper_hdl, char * time_origin, int time_origin_size) |
---|
56 | { |
---|
57 | CTimer::get("XIOS").resume(); |
---|
58 | if(!string_copy(calendar_wrapper_hdl->time_origin.getInheritedValue(),time_origin , time_origin_size)) |
---|
59 | ERROR("void cxios_get_calendar_wrapper_time_origin(calendar_wrapper_Ptr calendar_wrapper_hdl, char * time_origin, int time_origin_size)", <<"Input string is to short"); |
---|
60 | CTimer::get("XIOS").suspend(); |
---|
61 | } |
---|
62 | |
---|
63 | bool cxios_is_defined_calendar_wrapper_time_origin(calendar_wrapper_Ptr calendar_wrapper_hdl ) |
---|
64 | { |
---|
65 | CTimer::get("XIOS").resume(); |
---|
66 | return calendar_wrapper_hdl->time_origin.hasInheritedValue(); |
---|
67 | CTimer::get("XIOS").suspend(); |
---|
68 | } |
---|
69 | |
---|
70 | |
---|
71 | |
---|
72 | void cxios_set_calendar_wrapper_timestep(calendar_wrapper_Ptr calendar_wrapper_hdl, cxios_duration timestep_c) |
---|
73 | { |
---|
74 | CTimer::get("XIOS").resume(); |
---|
75 | calendar_wrapper_hdl->timestep.allocate(); |
---|
76 | CDuration& timestep = calendar_wrapper_hdl->timestep.get(); |
---|
77 | timestep.year = timestep_c.year; |
---|
78 | timestep.month = timestep_c.month; |
---|
79 | timestep.day = timestep_c.day; |
---|
80 | timestep.hour = timestep_c.hour; |
---|
81 | timestep.minute = timestep_c.minute; |
---|
82 | timestep.second = timestep_c.second; |
---|
83 | timestep.timestep = timestep_c.timestep; |
---|
84 | CTimer::get("XIOS").suspend(); |
---|
85 | } |
---|
86 | |
---|
87 | void cxios_get_calendar_wrapper_timestep(calendar_wrapper_Ptr calendar_wrapper_hdl, cxios_duration* timestep_c) |
---|
88 | { |
---|
89 | CTimer::get("XIOS").resume(); |
---|
90 | CDuration timestep = calendar_wrapper_hdl->timestep.getInheritedValue(); |
---|
91 | timestep_c->year = timestep.year; |
---|
92 | timestep_c->month = timestep.month; |
---|
93 | timestep_c->day = timestep.day; |
---|
94 | timestep_c->hour = timestep.hour; |
---|
95 | timestep_c->minute = timestep.minute; |
---|
96 | timestep_c->second = timestep.second; |
---|
97 | timestep_c->timestep = timestep.timestep; |
---|
98 | CTimer::get("XIOS").suspend(); |
---|
99 | } |
---|
100 | |
---|
101 | bool cxios_is_defined_calendar_wrapper_timestep(calendar_wrapper_Ptr calendar_wrapper_hdl ) |
---|
102 | { |
---|
103 | CTimer::get("XIOS").resume(); |
---|
104 | return calendar_wrapper_hdl->timestep.hasInheritedValue(); |
---|
105 | CTimer::get("XIOS").suspend(); |
---|
106 | } |
---|
107 | |
---|
108 | |
---|
109 | |
---|
110 | void cxios_set_calendar_wrapper_type(calendar_wrapper_Ptr calendar_wrapper_hdl, const char * type, int type_size) |
---|
111 | { |
---|
112 | std::string type_str; |
---|
113 | if(!cstr2string(type, type_size, type_str)) return; |
---|
114 | CTimer::get("XIOS").resume(); |
---|
115 | calendar_wrapper_hdl->type.fromString(type_str); |
---|
116 | CTimer::get("XIOS").suspend(); |
---|
117 | } |
---|
118 | |
---|
119 | void cxios_get_calendar_wrapper_type(calendar_wrapper_Ptr calendar_wrapper_hdl, char * type, int type_size) |
---|
120 | { |
---|
121 | CTimer::get("XIOS").resume(); |
---|
122 | if(!string_copy(calendar_wrapper_hdl->type.getInheritedStringValue(),type , type_size)) |
---|
123 | ERROR("void cxios_get_calendar_wrapper_type(calendar_wrapper_Ptr calendar_wrapper_hdl, char * type, int type_size)", <<"Input string is to short"); |
---|
124 | CTimer::get("XIOS").suspend(); |
---|
125 | } |
---|
126 | |
---|
127 | bool cxios_is_defined_calendar_wrapper_type(calendar_wrapper_Ptr calendar_wrapper_hdl ) |
---|
128 | { |
---|
129 | CTimer::get("XIOS").resume(); |
---|
130 | return calendar_wrapper_hdl->type.hasInheritedValue(); |
---|
131 | CTimer::get("XIOS").suspend(); |
---|
132 | } |
---|
133 | |
---|
134 | |
---|
135 | |
---|
136 | |
---|
137 | } |
---|