mirror of
https://github.com/OPM/ResInsight.git
synced 2026-10-25 06:38:13 -05:00
- Updated Python API to accept measured_depth list and channel_data dictionary - Modified C++ GRPC implementation to handle CSV-formatted channel mappings - Replaced single values parameter with dictionary of channels - Added comprehensive validation for all input parameters - Updated parameter name from channel_keys_json to channel_keys_csv - Enhanced tests to cover 16 different scenarios including edge cases - Updated example to demonstrate new dictionary-based API functionality
66 lines
2.4 KiB
C++
66 lines
2.4 KiB
C++
/////////////////////////////////////////////////////////////////////////////////
|
|
//
|
|
// Copyright (C) 2025 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 "cafPdmChildArrayField.h"
|
|
#include "cafPdmField.h"
|
|
#include "cafPdmObject.h"
|
|
#include "cvfObject.h"
|
|
|
|
#include <QString>
|
|
#include <vector>
|
|
|
|
class RigImportedWellLogData;
|
|
class RimWellLogChannelData;
|
|
|
|
//==================================================================================================
|
|
/// PDM class for storing imported well log data that can be persisted to project files
|
|
//==================================================================================================
|
|
class RimImportedWellLogData : public caf::PdmObject
|
|
{
|
|
CAF_PDM_HEADER_INIT;
|
|
|
|
public:
|
|
RimImportedWellLogData();
|
|
|
|
// Setters for data
|
|
void setDepthValues( const std::vector<double>& depths );
|
|
void setTvdMslValues( const std::vector<double>& tvdMsl );
|
|
void setTvdRkbValues( const std::vector<double>& tvdRkb );
|
|
void setChannelData( const QString& name, const std::vector<double>& values );
|
|
|
|
// Getters for data
|
|
std::vector<double> depthValues() const;
|
|
std::vector<double> tvdMslValues() const;
|
|
std::vector<double> tvdRkbValues() const;
|
|
std::vector<QString> channelNames() const;
|
|
std::vector<double> channelValues( const QString& name ) const;
|
|
|
|
bool hasTvdMslValues() const;
|
|
bool hasTvdRkbValues() const;
|
|
|
|
// Method to produce RigImportedWellLogData from PDM data
|
|
cvf::ref<RigImportedWellLogData> createRigData() const;
|
|
|
|
private:
|
|
caf::PdmField<std::vector<double>> m_depthValues;
|
|
caf::PdmField<std::vector<double>> m_tvdMslValues;
|
|
caf::PdmField<std::vector<double>> m_tvdRkbValues;
|
|
caf::PdmChildArrayField<RimWellLogChannelData*> m_channelDataObjects;
|
|
}; |