source: XIOS/trunk/src/interface/c_attr/icgrid_attr.cpp @ 347

Last change on this file since 347 was 347, checked in by ymipsl, 9 years ago
  • Supress lot of shared_ptr
  • instrument code for vampir-trace and timer diagnostic

YM

  • Property svn:eol-style set to native
File size: 3.5 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_impl.hpp"
9#include "object_template_impl.hpp"
10#include "group_template_impl.hpp"
11#include "icutil.hpp"
12#include "timer.hpp"
13
14extern "C"
15{
16  typedef xios::CGrid*  grid_Ptr;
17 
18  void cxios_set_grid_axis_ref(grid_Ptr grid_hdl, const char * axis_ref, int axis_ref_size)
19  {
20    std::string axis_ref_str;
21    if(!cstr2string(axis_ref, axis_ref_size, axis_ref_str)) return;
22     CTimer::get("XIOS").resume();
23    grid_hdl->axis_ref.setValue(axis_ref_str);
24    grid_hdl->sendAttributToServer(grid_hdl->axis_ref);
25     CTimer::get("XIOS").suspend();
26  }
27 
28  void cxios_get_grid_axis_ref(grid_Ptr grid_hdl, char * axis_ref, int axis_ref_size)
29  {
30     CTimer::get("XIOS").resume();
31    if(!string_copy(grid_hdl->axis_ref.getValue(),axis_ref , axis_ref_size))
32      ERROR("void cxios_get_grid_axis_ref(grid_Ptr grid_hdl, char * axis_ref, int axis_ref_size)", <<"Input string is to short");
33     CTimer::get("XIOS").suspend();
34  }
35 
36 
37  void cxios_set_grid_description(grid_Ptr grid_hdl, const char * description, int description_size)
38  {
39    std::string description_str;
40    if(!cstr2string(description, description_size, description_str)) return;
41     CTimer::get("XIOS").resume();
42    grid_hdl->description.setValue(description_str);
43    grid_hdl->sendAttributToServer(grid_hdl->description);
44     CTimer::get("XIOS").suspend();
45  }
46 
47  void cxios_get_grid_description(grid_Ptr grid_hdl, char * description, int description_size)
48  {
49     CTimer::get("XIOS").resume();
50    if(!string_copy(grid_hdl->description.getValue(),description , description_size))
51      ERROR("void cxios_get_grid_description(grid_Ptr grid_hdl, char * description, int description_size)", <<"Input string is to short");
52     CTimer::get("XIOS").suspend();
53  }
54 
55 
56  void cxios_set_grid_domain_ref(grid_Ptr grid_hdl, const char * domain_ref, int domain_ref_size)
57  {
58    std::string domain_ref_str;
59    if(!cstr2string(domain_ref, domain_ref_size, domain_ref_str)) return;
60     CTimer::get("XIOS").resume();
61    grid_hdl->domain_ref.setValue(domain_ref_str);
62    grid_hdl->sendAttributToServer(grid_hdl->domain_ref);
63     CTimer::get("XIOS").suspend();
64  }
65 
66  void cxios_get_grid_domain_ref(grid_Ptr grid_hdl, char * domain_ref, int domain_ref_size)
67  {
68     CTimer::get("XIOS").resume();
69    if(!string_copy(grid_hdl->domain_ref.getValue(),domain_ref , domain_ref_size))
70      ERROR("void cxios_get_grid_domain_ref(grid_Ptr grid_hdl, char * domain_ref, int domain_ref_size)", <<"Input string is to short");
71     CTimer::get("XIOS").suspend();
72  }
73 
74 
75  void cxios_set_grid_name(grid_Ptr grid_hdl, const char * name, int name_size)
76  {
77    std::string name_str;
78    if(!cstr2string(name, name_size, name_str)) return;
79     CTimer::get("XIOS").resume();
80    grid_hdl->name.setValue(name_str);
81    grid_hdl->sendAttributToServer(grid_hdl->name);
82     CTimer::get("XIOS").suspend();
83  }
84 
85  void cxios_get_grid_name(grid_Ptr grid_hdl, char * name, int name_size)
86  {
87     CTimer::get("XIOS").resume();
88    if(!string_copy(grid_hdl->name.getValue(),name , name_size))
89      ERROR("void cxios_get_grid_name(grid_Ptr grid_hdl, char * name, int name_size)", <<"Input string is to short");
90     CTimer::get("XIOS").suspend();
91  }
92 
93 
94 
95}
Note: See TracBrowser for help on using the repository browser.