Ignore:
Timestamp:
06/03/13 11:21:19 (8 years ago)
Author:
ymipsl
Message:

Enhancement : Add fortran interface to know if an attribute is set or not
ex : CALL xios_is_defined_field_attr("field_A",enabled=ok)

YM

File:
1 edited

Legend:

Unmodified
Added
Removed
  • XIOS/trunk/src/interface/c_attr/icgrid_attr.cpp

    r416 r432  
    3535  } 
    3636   
     37  bool cxios_is_defined_grid_axis_ref(grid_Ptr grid_hdl ) 
     38  { 
     39     CTimer::get("XIOS").resume(); 
     40    return !grid_hdl->axis_ref.isEmpty(); 
     41     CTimer::get("XIOS").suspend(); 
     42  } 
     43   
     44   
    3745   
    3846  void cxios_set_grid_description(grid_Ptr grid_hdl, const char * description, int description_size) 
     
    5361     CTimer::get("XIOS").suspend(); 
    5462  } 
     63   
     64  bool cxios_is_defined_grid_description(grid_Ptr grid_hdl ) 
     65  { 
     66     CTimer::get("XIOS").resume(); 
     67    return !grid_hdl->description.isEmpty(); 
     68     CTimer::get("XIOS").suspend(); 
     69  } 
     70   
    5571   
    5672   
     
    7389  } 
    7490   
     91  bool cxios_is_defined_grid_domain_ref(grid_Ptr grid_hdl ) 
     92  { 
     93     CTimer::get("XIOS").resume(); 
     94    return !grid_hdl->domain_ref.isEmpty(); 
     95     CTimer::get("XIOS").suspend(); 
     96  } 
     97   
     98   
    7599   
    76100  void cxios_set_grid_mask(grid_Ptr grid_hdl, bool* mask, int extent1, int extent2, int extent3) 
     
    90114     CTimer::get("XIOS").suspend(); 
    91115  } 
     116   
     117  bool cxios_is_defined_grid_mask(grid_Ptr grid_hdl ) 
     118  { 
     119     CTimer::get("XIOS").resume(); 
     120    return !grid_hdl->mask.isEmpty(); 
     121     CTimer::get("XIOS").suspend(); 
     122  } 
     123   
    92124   
    93125   
     
    110142  } 
    111143   
     144  bool cxios_is_defined_grid_name(grid_Ptr grid_hdl ) 
     145  { 
     146     CTimer::get("XIOS").resume(); 
     147    return !grid_hdl->name.isEmpty(); 
     148     CTimer::get("XIOS").suspend(); 
     149  } 
     150   
     151   
    112152   
    113153   
Note: See TracChangeset for help on using the changeset viewer.