///////////////////////////////////////////////////////////////////////////////// // // Copyright (C) 2023- 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 // for more details. // ///////////////////////////////////////////////////////////////////////////////// #pragma once #include #include #include namespace RimSummaryTableTools { // Struct for storing vector data struct VectorData { QString category; QString name; std::vector values; time_t firstTimeStep; time_t lastTimeStep; }; // Struct for storing table data struct TableData { std::vector vectorDataCollection; std::set timeStepsUnion; double maxValue = 0.0; double minValue = 0.0; double thresholdValue = 0.0; QString unitName; }; bool hasValueAboveThreshold( const std::vector& values, double thresholdValue ); std::vector vectorsAboveThreshold( const std::vector& vectorDataCollection, double thresholdValue ); void sortVectorDataOnDate( TableData& rTableData ); std::vector categoryNames( const std::vector& vectorDataCollection ); } // namespace RimSummaryTableTools