mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Osdu Well Log: cache channel meta data from Osdu.
This commit is contained in:
@@ -23,7 +23,7 @@ set(SOURCE_GROUP_HEADER_FILES
|
||||
${CMAKE_CURRENT_LIST_DIR}/RimWellLog.h
|
||||
${CMAKE_CURRENT_LIST_DIR}/RimWellLogFile.h
|
||||
${CMAKE_CURRENT_LIST_DIR}/RimWellLogFileUtil.h
|
||||
${CMAKE_CURRENT_LIST_DIR}/RimWellLogChannel.h
|
||||
${CMAKE_CURRENT_LIST_DIR}/RimOsduWellLogChannel.h
|
||||
${CMAKE_CURRENT_LIST_DIR}/RimWellLogLasFileCurve.h
|
||||
${CMAKE_CURRENT_LIST_DIR}/RimWellLogRftCurve.h
|
||||
${CMAKE_CURRENT_LIST_DIR}/RimWellLogWbsCurve.h
|
||||
@@ -46,6 +46,7 @@ set(SOURCE_GROUP_SOURCE_FILES
|
||||
${CMAKE_CURRENT_LIST_DIR}/RimWellLogFile.cpp
|
||||
${CMAKE_CURRENT_LIST_DIR}/RimWellLogFileUtil.cpp
|
||||
${CMAKE_CURRENT_LIST_DIR}/RimWellLogChannel.cpp
|
||||
${CMAKE_CURRENT_LIST_DIR}/RimOsduWellLogChannel.cpp
|
||||
${CMAKE_CURRENT_LIST_DIR}/RimWellLogLasFileCurve.cpp
|
||||
${CMAKE_CURRENT_LIST_DIR}/RimWellLogRftCurve.cpp
|
||||
${CMAKE_CURRENT_LIST_DIR}/RimWellLogWbsCurve.cpp
|
||||
|
||||
@@ -20,8 +20,8 @@
|
||||
|
||||
#include "RiaFieldHandleTools.h"
|
||||
|
||||
#include "RimOsduWellLogChannel.h"
|
||||
#include "RimTools.h"
|
||||
#include "RimWellLogChannel.h"
|
||||
#include "RimWellPath.h"
|
||||
#include "RimWellPathCollection.h"
|
||||
#include "RimWellPlotTools.h"
|
||||
@@ -146,15 +146,6 @@ RigOsduWellLogData* RimOsduWellLog::wellLogData()
|
||||
void RimOsduWellLog::setWellLogData( RigOsduWellLogData* wellLogData )
|
||||
{
|
||||
m_wellLogData = wellLogData;
|
||||
|
||||
m_wellLogChannels.deleteChildren();
|
||||
|
||||
for ( const QString& wellLogName : wellLogData->wellLogChannelNames() )
|
||||
{
|
||||
RimWellLogChannel* wellLog = new RimWellLogChannel();
|
||||
wellLog->setName( wellLogName );
|
||||
m_wellLogChannels.push_back( wellLog );
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -172,3 +163,11 @@ QString RimOsduWellLog::wellLogId() const
|
||||
{
|
||||
return m_wellLogId;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimOsduWellLog::addWellLogChannel( RimOsduWellLogChannel* channel )
|
||||
{
|
||||
m_wellLogChannels.push_back( channel );
|
||||
}
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
|
||||
#include <QDateTime>
|
||||
|
||||
class RimWellLogChannel;
|
||||
class RimOsduWellLogChannel;
|
||||
class RimWellPath;
|
||||
|
||||
class QString;
|
||||
@@ -54,6 +54,8 @@ public:
|
||||
RigOsduWellLogData* wellLogData() override;
|
||||
void setWellLogData( RigOsduWellLogData* wellLogData );
|
||||
|
||||
void addWellLogChannel( RimOsduWellLogChannel* channel );
|
||||
|
||||
void setWellLogId( const QString& wellLogId );
|
||||
QString wellLogId() const;
|
||||
|
||||
|
||||
@@ -0,0 +1,108 @@
|
||||
/////////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Copyright (C) 2024- 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.
|
||||
//
|
||||
/////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "RimOsduWellLogChannel.h"
|
||||
|
||||
#include "RiaFieldHandleTools.h"
|
||||
|
||||
CAF_PDM_SOURCE_INIT( RimOsduWellLogChannel, "OsduWellLogChannel" );
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RimOsduWellLogChannel::RimOsduWellLogChannel()
|
||||
{
|
||||
CAF_PDM_InitObject( "OSDU Well Log Channel" );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_description, "Description", "Description" );
|
||||
m_description.uiCapability()->setUiReadOnly( true );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_topDepth, "TopDepth", "Top Depth" );
|
||||
m_topDepth.uiCapability()->setUiReadOnly( true );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_baseDepth, "BaseDepth", "Base Depth" );
|
||||
m_baseDepth.uiCapability()->setUiReadOnly( true );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_interpreterName, "InterpreterName", "Interpreter Name" );
|
||||
m_interpreterName.uiCapability()->setUiReadOnly( true );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_quality, "Quality", "Quality" );
|
||||
m_quality.uiCapability()->setUiReadOnly( true );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_unit, "Unit", "Unit" );
|
||||
m_unit.uiCapability()->setUiReadOnly( true );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_depthUnit, "DepthUnit", "Depth Unit" );
|
||||
m_depthUnit.uiCapability()->setUiReadOnly( true );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimOsduWellLogChannel::setDescription( const QString& description )
|
||||
{
|
||||
m_description = description;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimOsduWellLogChannel::setTopDepth( double topDepth )
|
||||
{
|
||||
m_topDepth = topDepth;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimOsduWellLogChannel::setBaseDepth( double baseDepth )
|
||||
{
|
||||
m_baseDepth = baseDepth;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimOsduWellLogChannel::setInterpreterName( const QString& interpreterName )
|
||||
{
|
||||
m_interpreterName = interpreterName;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimOsduWellLogChannel::setQuality( const QString& quality )
|
||||
{
|
||||
m_quality = quality;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimOsduWellLogChannel::setUnit( const QString& unit )
|
||||
{
|
||||
m_unit = unit;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimOsduWellLogChannel::setDepthUnit( const QString& depthUnit )
|
||||
{
|
||||
m_depthUnit = depthUnit;
|
||||
}
|
||||
@@ -0,0 +1,50 @@
|
||||
/////////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Copyright (C) 2024- 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 "RimWellLogChannel.h"
|
||||
|
||||
//==================================================================================================
|
||||
///
|
||||
///
|
||||
//==================================================================================================
|
||||
class RimOsduWellLogChannel : public RimWellLogChannel
|
||||
{
|
||||
CAF_PDM_HEADER_INIT;
|
||||
|
||||
public:
|
||||
RimOsduWellLogChannel();
|
||||
|
||||
void setDescription( const QString& description );
|
||||
void setTopDepth( double topDepth );
|
||||
void setBaseDepth( double baseDepth );
|
||||
void setInterpreterName( const QString& interpreterName );
|
||||
void setQuality( const QString& quality );
|
||||
void setUnit( const QString& unit );
|
||||
void setDepthUnit( const QString& depthUnit );
|
||||
|
||||
private:
|
||||
caf::PdmField<QString> m_description;
|
||||
caf::PdmField<double> m_topDepth;
|
||||
caf::PdmField<double> m_baseDepth;
|
||||
caf::PdmField<QString> m_interpreterName;
|
||||
caf::PdmField<QString> m_quality;
|
||||
caf::PdmField<QString> m_unit;
|
||||
caf::PdmField<QString> m_depthUnit;
|
||||
};
|
||||
Reference in New Issue
Block a user