source: XIOS/trunk/src/interface/c_attr/icgridgroup_attr.cpp @ 674

Last change on this file since 674 was 674, checked in by rlacroix, 6 years ago

Fix Fortran interface generation to avoid generating long lines.

Long lines can cause compilation issues with some compilers.

  • Property copyright set to
    Software name : XIOS (Xml I/O Server)
    http://forge.ipsl.jussieu.fr/ioserver
    Creation date : January 2009
    Licence : CeCCIL version2
    see license file in root directory : Licence_CeCILL_V2-en.txt
    or http://www.cecill.info/licences/Licence_CeCILL_V2-en.html
    Holder : CEA/LSCE (Laboratoire des Sciences du CLimat et de l'Environnement)
    CNRS/IPSL (Institut Pierre Simon Laplace)
    Project Manager : Yann Meurdesoif
    yann.meurdesoif@cea.fr
  • Property svn:eol-style set to native
File size: 6.8 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 "xios.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
16extern "C"
17{
18  typedef xios::CGridGroup* gridgroup_Ptr;
19
20  void cxios_set_gridgroup_axis_domain_order(gridgroup_Ptr gridgroup_hdl, bool* axis_domain_order, int* extent)
21  {
22    CTimer::get("XIOS").resume();
23    CArray<bool,1> tmp(axis_domain_order, shape(extent[0]), neverDeleteData);
24    gridgroup_hdl->axis_domain_order.reference(tmp.copy());
25     CTimer::get("XIOS").suspend();
26  }
27
28  void cxios_get_gridgroup_axis_domain_order(gridgroup_Ptr gridgroup_hdl, bool* axis_domain_order, int* extent)
29  {
30    CTimer::get("XIOS").resume();
31    CArray<bool,1> tmp(axis_domain_order, shape(extent[0]), neverDeleteData);
32    tmp=gridgroup_hdl->axis_domain_order.getInheritedValue();
33     CTimer::get("XIOS").suspend();
34  }
35
36  bool cxios_is_defined_gridgroup_axis_domain_order(gridgroup_Ptr gridgroup_hdl)
37  {
38     CTimer::get("XIOS").resume();
39     bool isDefined = gridgroup_hdl->axis_domain_order.hasInheritedValue();
40     CTimer::get("XIOS").suspend();
41     return isDefined;
42  }
43
44
45  void cxios_set_gridgroup_description(gridgroup_Ptr gridgroup_hdl, const char * description, int description_size)
46  {
47    std::string description_str;
48    if (!cstr2string(description, description_size, description_str)) return;
49    CTimer::get("XIOS").resume();
50    gridgroup_hdl->description.setValue(description_str);
51    CTimer::get("XIOS").suspend();
52  }
53
54  void cxios_get_gridgroup_description(gridgroup_Ptr gridgroup_hdl, char * description, int description_size)
55  {
56    CTimer::get("XIOS").resume();
57    if (!string_copy(gridgroup_hdl->description.getInheritedValue(), description, description_size))
58      ERROR("void cxios_get_gridgroup_description(gridgroup_Ptr gridgroup_hdl, char * description, int description_size)", << "Input string is too short");
59    CTimer::get("XIOS").suspend();
60  }
61
62  bool cxios_is_defined_gridgroup_description(gridgroup_Ptr gridgroup_hdl)
63  {
64     CTimer::get("XIOS").resume();
65     bool isDefined = gridgroup_hdl->description.hasInheritedValue();
66     CTimer::get("XIOS").suspend();
67     return isDefined;
68  }
69
70
71  void cxios_set_gridgroup_group_ref(gridgroup_Ptr gridgroup_hdl, const char * group_ref, int group_ref_size)
72  {
73    std::string group_ref_str;
74    if (!cstr2string(group_ref, group_ref_size, group_ref_str)) return;
75    CTimer::get("XIOS").resume();
76    gridgroup_hdl->group_ref.setValue(group_ref_str);
77    CTimer::get("XIOS").suspend();
78  }
79
80  void cxios_get_gridgroup_group_ref(gridgroup_Ptr gridgroup_hdl, char * group_ref, int group_ref_size)
81  {
82    CTimer::get("XIOS").resume();
83    if (!string_copy(gridgroup_hdl->group_ref.getInheritedValue(), group_ref, group_ref_size))
84      ERROR("void cxios_get_gridgroup_group_ref(gridgroup_Ptr gridgroup_hdl, char * group_ref, int group_ref_size)", << "Input string is too short");
85    CTimer::get("XIOS").suspend();
86  }
87
88  bool cxios_is_defined_gridgroup_group_ref(gridgroup_Ptr gridgroup_hdl)
89  {
90     CTimer::get("XIOS").resume();
91     bool isDefined = gridgroup_hdl->group_ref.hasInheritedValue();
92     CTimer::get("XIOS").suspend();
93     return isDefined;
94  }
95
96
97  void cxios_set_gridgroup_mask1(gridgroup_Ptr gridgroup_hdl, bool* mask1, int* extent)
98  {
99    CTimer::get("XIOS").resume();
100    CArray<bool,1> tmp(mask1, shape(extent[0]), neverDeleteData);
101    gridgroup_hdl->mask1.reference(tmp.copy());
102     CTimer::get("XIOS").suspend();
103  }
104
105  void cxios_get_gridgroup_mask1(gridgroup_Ptr gridgroup_hdl, bool* mask1, int* extent)
106  {
107    CTimer::get("XIOS").resume();
108    CArray<bool,1> tmp(mask1, shape(extent[0]), neverDeleteData);
109    tmp=gridgroup_hdl->mask1.getInheritedValue();
110     CTimer::get("XIOS").suspend();
111  }
112
113  bool cxios_is_defined_gridgroup_mask1(gridgroup_Ptr gridgroup_hdl)
114  {
115     CTimer::get("XIOS").resume();
116     bool isDefined = gridgroup_hdl->mask1.hasInheritedValue();
117     CTimer::get("XIOS").suspend();
118     return isDefined;
119  }
120
121
122  void cxios_set_gridgroup_mask2(gridgroup_Ptr gridgroup_hdl, bool* mask2, int* extent)
123  {
124    CTimer::get("XIOS").resume();
125    CArray<bool,2> tmp(mask2, shape(extent[0], extent[1]), neverDeleteData);
126    gridgroup_hdl->mask2.reference(tmp.copy());
127     CTimer::get("XIOS").suspend();
128  }
129
130  void cxios_get_gridgroup_mask2(gridgroup_Ptr gridgroup_hdl, bool* mask2, int* extent)
131  {
132    CTimer::get("XIOS").resume();
133    CArray<bool,2> tmp(mask2, shape(extent[0], extent[1]), neverDeleteData);
134    tmp=gridgroup_hdl->mask2.getInheritedValue();
135     CTimer::get("XIOS").suspend();
136  }
137
138  bool cxios_is_defined_gridgroup_mask2(gridgroup_Ptr gridgroup_hdl)
139  {
140     CTimer::get("XIOS").resume();
141     bool isDefined = gridgroup_hdl->mask2.hasInheritedValue();
142     CTimer::get("XIOS").suspend();
143     return isDefined;
144  }
145
146
147  void cxios_set_gridgroup_mask3(gridgroup_Ptr gridgroup_hdl, bool* mask3, int* extent)
148  {
149    CTimer::get("XIOS").resume();
150    CArray<bool,3> tmp(mask3, shape(extent[0], extent[1], extent[2]), neverDeleteData);
151    gridgroup_hdl->mask3.reference(tmp.copy());
152     CTimer::get("XIOS").suspend();
153  }
154
155  void cxios_get_gridgroup_mask3(gridgroup_Ptr gridgroup_hdl, bool* mask3, int* extent)
156  {
157    CTimer::get("XIOS").resume();
158    CArray<bool,3> tmp(mask3, shape(extent[0], extent[1], extent[2]), neverDeleteData);
159    tmp=gridgroup_hdl->mask3.getInheritedValue();
160     CTimer::get("XIOS").suspend();
161  }
162
163  bool cxios_is_defined_gridgroup_mask3(gridgroup_Ptr gridgroup_hdl)
164  {
165     CTimer::get("XIOS").resume();
166     bool isDefined = gridgroup_hdl->mask3.hasInheritedValue();
167     CTimer::get("XIOS").suspend();
168     return isDefined;
169  }
170
171
172  void cxios_set_gridgroup_name(gridgroup_Ptr gridgroup_hdl, const char * name, int name_size)
173  {
174    std::string name_str;
175    if (!cstr2string(name, name_size, name_str)) return;
176    CTimer::get("XIOS").resume();
177    gridgroup_hdl->name.setValue(name_str);
178    CTimer::get("XIOS").suspend();
179  }
180
181  void cxios_get_gridgroup_name(gridgroup_Ptr gridgroup_hdl, char * name, int name_size)
182  {
183    CTimer::get("XIOS").resume();
184    if (!string_copy(gridgroup_hdl->name.getInheritedValue(), name, name_size))
185      ERROR("void cxios_get_gridgroup_name(gridgroup_Ptr gridgroup_hdl, char * name, int name_size)", << "Input string is too short");
186    CTimer::get("XIOS").suspend();
187  }
188
189  bool cxios_is_defined_gridgroup_name(gridgroup_Ptr gridgroup_hdl)
190  {
191     CTimer::get("XIOS").resume();
192     bool isDefined = gridgroup_hdl->name.hasInheritedValue();
193     CTimer::get("XIOS").suspend();
194     return isDefined;
195  }
196}
Note: See TracBrowser for help on using the repository browser.