Improve summary category detection for opm-common reader (#9018)

* Move code to quantitynameinforprovider
* Use some region-to-region helper function from opm-common
* Add more fallbacks
This commit is contained in:
Magne Sjaastad
2022-06-03 13:54:15 +02:00
committed by GitHub
parent 95e9ef8bf1
commit 2472f4697c
6 changed files with 101 additions and 42 deletions

View File

@@ -23,6 +23,8 @@
#include "RifEclipseUserDataParserTools.h"
#include "RiuSummaryQuantityNameInfoProvider.h"
#include <QStringList>
//--------------------------------------------------------------------------------------------------
@@ -164,7 +166,8 @@ bool RifEclipseUserDataKeywordTools::isYearX( const std::string& identifier )
RifEclipseSummaryAddress RifEclipseUserDataKeywordTools::makeAndFillAddress( const std::string quantityName,
const std::vector<std::string>& columnHeaderText )
{
RifEclipseSummaryAddress::SummaryVarCategory category = RifEclipseSummaryAddress::identifyCategory( quantityName );
RifEclipseSummaryAddress::SummaryVarCategory category =
RiuSummaryQuantityNameInfoProvider::instance()->identifyCategory( quantityName );
if ( category == RifEclipseSummaryAddress::SUMMARY_INVALID )
{