source: XIOS/trunk/src/io/netCdf_cf_constant.hpp @ 887

Last change on this file since 887 was 782, checked in by mhnguyen, 8 years ago

Reading attributes of curvilinear grid from file

+) Correct some minor bugs detecting type of grid
+) Use constant string for attributes conforming to CF convention
+) Add part of code to read attributes of curvilinear grid

Test
+) On Curie
+) test_remap passes

File size: 1.3 KB
Line 
1#ifndef __XIOS_INETCDF4_IMPL__
2#define __XIOS_INETCDF4_IMPL__
3
4#include "inetcdf4.hpp"
5#include "netCdfInterface.hpp"
6
7namespace xios
8{
9const StdString CFLatUnits[] = {"degrees_north", "degree_north", "degree_N", "degrees_N", "degreeN", "degreesN"};
10const StdString CFLonUnits[] = {"degrees_east", "degree_east", "degree_E", "degrees_E", "degreeE", "degreesE"};
11
12struct CCFKeywords
13{
14  static const StdString XIOS_CF_units;
15  static const StdString XIOS_CF_standard_name;
16  static const StdString XIOS_CF_coordinates;
17  static const StdString XIOS_CF_bounds;
18};
19const StdString CCFKeywords::XIOS_CF_units("units");
20const StdString CCFKeywords::XIOS_CF_standard_name("standard_name");
21const StdString CCFKeywords::XIOS_CF_coordinates("coordinates");
22const StdString CCFKeywords::XIOS_CF_bounds("bounds");
23
24struct CCFConvention
25{
26  static const std::set<StdString> XIOS_CF_Latitude_units;
27  static const std::set<StdString> XIOS_CF_Longitude_units;
28
29private:
30  CCFConvention();
31};
32
33const std::set<StdString> CCFConvention::XIOS_CF_Latitude_units(CFLatUnits, CFLatUnits+sizeof(CFLatUnits)/sizeof(CFLatUnits[0]));
34const std::set<StdString> CCFConvention::XIOS_CF_Longitude_units(CFLonUnits, CFLonUnits+sizeof(CFLonUnits)/sizeof(CFLonUnits[0]));
35
36} // namespace xios
37
38#endif //__XIOS_INETCDF4_IMPL__
Note: See TracBrowser for help on using the repository browser.