Ignore:
Timestamp:
06/28/22 11:59:40 (2 years ago)
Author:
jderouillat
Message:

Forced usage of extract_domain when zoom_domain is specified, added messages to inform users of required modifications.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • XIOS/dev/dev_ym/XIOS_COUPLING/src/interface/c/iczoom.cpp

    r1622 r2339  
    1515#include "icutil.hpp" 
    1616#include "timer.hpp" 
    17 #include "zoom_axis.hpp" 
    18 #include "zoom_domain.hpp" 
     17#include "extract_axis.hpp" 
     18#include "extract_domain.hpp" 
    1919 
    2020extern "C" 
     
    2424   // ----------------------- Redéfinition de types ---------------------------- 
    2525 
    26    typedef xios::CZoomAxis   * XZoomAxisPtr; 
    27    typedef xios::CZoomDomain * XZoomDomainPtr; 
     26   typedef xios::CExtractAxis   * XExtractAxisPtr; 
     27   typedef xios::CExtractDomain * XExtractDomainPtr; 
    2828   // ------------------------ Création des handle ----------------------------- 
    29    void cxios_zoom_axis_handle_create (XZoomAxisPtr * _ret, const char * _id, int _id_len) 
     29   void cxios_zoom_axis_handle_create (XExtractAxisPtr * _ret, const char * _id, int _id_len) 
    3030   TRY 
    3131   { 
    3232      std::string id; 
    3333      if (!cstr2string(_id, _id_len, id)) return; 
     34      cout << "WARNING : you are using the zoom_axis interface. zoom_domain is deprecated, replace it with extract_axis." << endl; 
     35      cout << "\t Calls to xios_set/get_zoom_axis_attr must be replaced with xios_set/get_extract_axis_attr in your model." << endl; 
    3436      CTimer::get("XIOS").resume() ; 
    35       *_ret = xios::CZoomAxis::get(id); 
     37      *_ret = xios::CExtractAxis::get(id); 
    3638      CTimer::get("XIOS").suspend() ; 
    3739   } 
     
    4446      std::string id; 
    4547      if (!cstr2string(_id, _id_len, id)) return; 
     48      cout << "WARNING : you are using the zoom_axis interface. zoom_domain is deprecated, replace it with extract_axis." << endl; 
     49      cout << "\t Calls to xios_set/get_zoom_axis_attr must be replaced with xios_set/get_extract_axis_attr in your model." << endl; 
    4650 
    4751      CTimer::get("XIOS").resume() ; 
    48       *_ret = xios::CZoomAxis::has(id); 
     52      *_ret = xios::CExtractAxis::has(id); 
    4953      CTimer::get("XIOS").suspend() ; 
    5054   } 
     
    5256 
    5357   // ------------------------ Création des handle ----------------------------- 
    54    void cxios_zoom_domain_handle_create(XZoomDomainPtr * _ret, const char * _id, int _id_len) 
     58   void cxios_zoom_domain_handle_create(XExtractDomainPtr * _ret, const char * _id, int _id_len) 
    5559   TRY 
    5660   { 
    5761      std::string id; 
    5862      if (!cstr2string(_id, _id_len, id)) return; 
     63      cout << "WARNING : you are using the zoom_domain interface. zoom_domain is deprecated, replace it with extract_domain." << endl; 
     64      cout << "\t Calls to xios_set/get_zoom_domain_attr must be replaced with xios_set/get_extract_domain_attr in your model." << endl; 
    5965      CTimer::get("XIOS").resume() ; 
    60       *_ret = xios::CZoomDomain::get(id); 
     66      *_ret = xios::CExtractDomain::get(id); 
    6167      CTimer::get("XIOS").suspend() ; 
    6268   } 
     
    6975      std::string id; 
    7076      if (!cstr2string(_id, _id_len, id)) return; 
    71  
     77      cout << "WARNING : you are using the zoom_domain interface. zoom_domain is deprecated, replace it with extract_domain." << endl; 
     78      cout << "\t Calls to xios_set/get_zoom_domain_attr must be replaced with xios_set/get_extract_domain_attr in your model." << endl; 
    7279      CTimer::get("XIOS").resume() ; 
    73       *_ret = xios::CZoomDomain::has(id); 
     80      *_ret = xios::CExtractDomain::has(id); 
    7481      CTimer::get("XIOS").suspend() ; 
    7582   } 
Note: See TracChangeset for help on using the changeset viewer.