source: XIOS/dev/dev_ym/XIOS_COUPLING/src/filter/transform_filter.hpp @ 2338

Last change on this file since 2338 was 2270, checked in by ymipsl, 3 years ago

Tracking memory leak :
Tranformations and algorithms are now managed with shared_ptr.

YM

  • Property svn:executable set to *
File size: 1.1 KB
Line 
1#ifndef __XIOS_TRANSFORM_FILTER_HPP__
2#define __XIOS_TRANSFORM_FILTER_HPP__
3
4#include "filter.hpp"
5#include "grid_algorithm.hpp"
6
7namespace xios
8{
9 
10  /*!
11   * A generic filter with multiple input slots wrapping any type of spatial transformations.
12   */
13  class CTransformFilter : public CFilter, IFilterEngine
14  {
15    public:
16
17      CTransformFilter(CGarbageCollector& gc, int slots, shared_ptr<CGridAlgorithm> algo, bool detectMissingValues, double defaultValue) ;
18
19    protected:
20      /*!
21        Overriding this function to process transformations with auxillary inputs
22      */
23      CDataPacketPtr virtual apply(std::vector<CDataPacketPtr> data) ;
24      void buildWorkflowGraph(std::vector<CDataPacketPtr> data, CDataPacketPtr packet, shared_ptr<CGridAlgorithm> algorithm);
25     
26//      void apply(const CArray<double, 1>& dataSrc, CArray<double,1>& dataDest);
27     
28      shared_ptr<CGridAlgorithm> algorithm_ ;
29      bool detectMissingValues_ ;
30      bool defaultValue_ ;
31
32  }; // class CTransformFilter
33
34
35} // namespace xios
36
37#endif //__XIOS_CSpatialTransformFilter__
Note: See TracBrowser for help on using the repository browser.