Ignore:
Timestamp:
12/07/21 12:07:33 (3 years ago)
Author:
ymipsl
Message:

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

YM

File:
1 edited

Legend:

Unmodified
Added
Removed
  • XIOS/dev/dev_ym/XIOS_COUPLING/src/transformation/generic_algorithm_transformation.hpp

    r2267 r2270  
    3232  This class defines the interface for all other inherited algorithms class 
    3333  */ 
    34 class CGenericAlgorithmTransformation 
     34class CGenericAlgorithmTransformation : public std::enable_shared_from_this<CGenericAlgorithmTransformation> 
    3535{ 
    3636  public :  
    3737    CGenericAlgorithmTransformation(bool isSource) ; 
    38     virtual CGridAlgorithm* createGridAlgorithm(CGrid* gridSrc, CGrid* newGrid, int pos) ; 
    39     virtual CTransformFilter* createTransformFilter(CGarbageCollector& gc, CGridAlgorithm* algo, bool detectMissingValues, double defaultValue) ; 
     38    virtual shared_ptr<CGridAlgorithm> createGridAlgorithm(CGrid* gridSrc, CGrid* newGrid, int pos) ; 
     39    virtual CTransformFilter* createTransformFilter(CGarbageCollector& gc, shared_ptr<CGridAlgorithm> algo, bool detectMissingValues, double defaultValue) ; 
    4040    virtual void apply(int dimBefore, int dimAfter, const CArray<double,1>& dataIn, CArray<double,1>& dataOut) { abort() ;} //=0 
    4141    virtual void apply(int dimBefore, int dimAfter, const CArray<double,1>& dataIn, const vector<CArray<double,1>>& auxData, CArray<double,1>& dataOut) { abort() ;} //=0 
Note: See TracChangeset for help on using the changeset viewer.