ResInsight/ApplicationLibCode/ProjectDataModel/RimGridCalculationCollection.h
Magne Sjaastad 39fc9d5c36 Add support for grid calculations as data source for statistics
- add data source selection, either Case Property or Grid Calculation
- add Time Step Selection, can be used for both dynamic case properties and Grid Calculations
- optionally release grid calculation data when statistics is computed
- recursive grid calculations is supported
2023-11-08 08:39:04 +01:00

47 lines
1.7 KiB
C++

/////////////////////////////////////////////////////////////////////////////////
//
// Copyright (C) 2022 Equinor ASA
//
// ResInsight is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// ResInsight is distributed in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or
// FITNESS FOR A PARTICULAR PURPOSE.
//
// See the GNU General Public License at <http://www.gnu.org/licenses/gpl.html>
// for more details.
//
/////////////////////////////////////////////////////////////////////////////////
#pragma once
#include "RimGridCalculation.h"
#include "RimUserDefinedCalculationCollection.h"
//==================================================================================================
///
///
//==================================================================================================
class RimGridCalculationCollection : public RimUserDefinedCalculationCollection
{
CAF_PDM_HEADER_INIT;
public:
RimGridCalculationCollection();
void rebuildCaseMetaData() override;
RimGridCalculation* createCalculation() const override;
std::vector<RimGridCalculation*> sortedGridCalculations() const;
std::vector<RimGridCalculation*> dependentCalculations( RimGridCalculation* sourceCalculation ) const;
private:
RimGridCalculation* findCalculation( const QString& calculationName ) const;
bool dependentCalculationsRecursively( RimGridCalculation* sourceCalculation, std::vector<RimGridCalculation*>& calculations ) const;
void initAfterRead() override;
};