source: XIOS/dev/dev_ym/XIOS_COUPLING/src/transformation/scalar_algorithm/scalar_algorithm_reduce_domain.hpp @ 2145

Last change on this file since 2145 was 2145, checked in by yushan, 3 years ago

Big commit on graph functionality. Add algo name for showing in the workflow graph

  • Property svn:executable set to *
File size: 1.9 KB
Line 
1/*!
2   \file scalar_algorithm_reduce_scalar.hpp
3   \author Ha NGUYEN
4   \since 13 Oct 2016
5   \date 13 Oct 2016
6
7   \brief Algorithm for reduce an DOMAIN to a scalar
8 */
9#ifndef __XIOS_SCALAR_ALGORITHM_REDUCE_DOMAIN_HPP__
10#define __XIOS_SCALAR_ALGORITHM_REDUCE_DOMAIN_HPP__
11
12#include "algorithm_transformation_reduce.hpp"
13#include "transformation.hpp"
14
15namespace xios {
16
17class CScalar;
18class CDomain;
19class CReduceDomainToScalar;
20class CReductionAlgorithm;
21
22/*!
23  \class CScalarAlgorithmReduceDomain
24  Reducing an DOMAIN to a scalar
25*/
26class CScalarAlgorithmReduceDomain : public CAlgorithmTransformationReduce
27{
28public:
29  CScalarAlgorithmReduceDomain(bool isSource, CScalar* scalarDestination, CDomain* domainSource, CReduceDomainToScalar* algo);
30
31  virtual ~CScalarAlgorithmReduceDomain();
32
33  static bool registerTrans();
34
35  virtual StdString getAlgoName() {return "\\nreduce_domain";}
36
37protected:
38  CDomain* domainSrc_ ;
39
40
41public:
42  static CGenericAlgorithmTransformation* create(bool isSource, CGrid* gridDst, CGrid* gridSrc,
43                                                CTransformation<CScalar>* transformation,
44                                                int elementPositionInGrid,
45                                                std::map<int, int>& elementPositionInGridSrc2ScalarPosition,
46                                                std::map<int, int>& elementPositionInGridSrc2DOMAINPosition,
47                                                std::map<int, int>& elementPositionInGridSrc2DomainPosition,
48                                                std::map<int, int>& elementPositionInGridDst2ScalarPosition,
49                                                std::map<int, int>& elementPositionInGridDst2DOMAINPosition,
50                                                std::map<int, int>& elementPositionInGridDst2DomainPosition);
51  static bool dummyRegistered_;
52};
53
54}
55#endif // __XIOS_SCALAR_ALGORITHM_REDUCE_DOMAIN_HPP__
Note: See TracBrowser for help on using the repository browser.