source: XIOS/dev/dev_trunk_graph/src/transformation/axis_algorithm/axis_algorithm_extract.hpp @ 2030

Last change on this file since 2030 was 2030, checked in by yushan, 6 months ago

Graph intermediate commit to a tmp branch.

  • Property svn:executable set to *
File size: 2.1 KB
Line 
1/*!
2   \file axis_algorithm_extract.hpp
3   \brief Algorithm for extracting an axis.
4 */
5#ifndef __XIOS_AXIS_ALGORITHM_EXTRACT_HPP__
6#define __XIOS_AXIS_ALGORITHM_EXTRACT_HPP__
7
8#include "algorithm_transformation_transfer.hpp"
9#include "transformation.hpp"
10
11namespace xios {
12class CAxis;
13class CExtractAxis;
14
15/*!
16  \class CAxisAlgorithmExtract
17  Implementing extract on axis
18  A extracted region can be considered as region that isn't masked.
19  Only this extracted region is extracted to write on Netcdf.
20*/
21class CAxisAlgorithmExtract : public CAlgorithmTransformationTransfer
22{
23public:
24  CAxisAlgorithmExtract(bool isSource, CAxis* axisDestination, CAxis* axisSource, CExtractAxis* extractAxis);
25
26  virtual ~CAxisAlgorithmExtract() {}
27
28  static bool registerTrans();
29  virtual StdString getAlgoName() {return "\\nextract_axis";}
30
31private:
32
33private:
34  //! Global extract begin on axis
35  StdSize extractBegin_;
36
37  //! Global extract end on axis
38  StdSize extractEnd_;
39
40  //! Global extract size on axis
41  StdSize extractN_;
42
43  std::vector<int> extractIndex_;
44
45private:
46  CAxis* axisSrc_;
47  CAxis* axisDest_;
48
49public:
50  static CGenericAlgorithmTransformation* create(bool isSource, CGrid* gridDst, CGrid* gridSrc,
51                                                CTransformation<CAxis>* transformation,
52                                                int elementPositionInGrid,
53                                                std::map<int, int>& elementPositionInGridSrc2ScalarPosition,
54                                                std::map<int, int>& elementPositionInGridSrc2AxisPosition,
55                                                std::map<int, int>& elementPositionInGridSrc2DomainPosition,
56                                                std::map<int, int>& elementPositionInGridDst2ScalarPosition,
57                                                std::map<int, int>& elementPositionInGridDst2AxisPosition,
58                                                std::map<int, int>& elementPositionInGridDst2DomainPosition);
59  static bool dummyRegistered_;
60};
61
62}
63#endif // __XIOS_AXIS_ALGORITHM_EXTRACT_HPP__
Note: See TracBrowser for help on using the repository browser.