///////////////////////////////////////////////////////////////////////////////// // // Copyright (C) 2018- 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 "RifElementPropertyTableReader.h" #include "cvfObject.h" #include "cvfVector3.h" #include #include #include #include //================================================================================================== // // //================================================================================================== class RifElementPropertyReader : public cvf::Object { public: RifElementPropertyReader( const std::vector& elementIdxToId ); ~RifElementPropertyReader() override; void addFile( const std::string& fileName ); void removeFile( const std::string& fileName ); std::vector scalarElementFields() const; std::map> readAllElementPropertiesInFileContainingField( const std::string& fieldName ); std::vector fieldsInFile( const std::string& fileName ) const; private: void makeElementIdToIdxMap(); static void outputWarningAboutWrongFileData(); private: std::map m_fieldsMetaData; std::vector m_elementIdxToId; std::unordered_map m_elementIdToIdx; };