diff --git a/ApplicationCode/Commands/RicAddWellLogToPlotFeature.cpp b/ApplicationCode/Commands/RicAddWellLogToPlotFeature.cpp index 8709ca8d54..e8c6804f5b 100644 --- a/ApplicationCode/Commands/RicAddWellLogToPlotFeature.cpp +++ b/ApplicationCode/Commands/RicAddWellLogToPlotFeature.cpp @@ -22,7 +22,7 @@ #include "RicWellLogPlotCurveFeatureImpl.h" #include "RicNewWellLogPlotFeatureImpl.h" -#include "RimWellLasFileInfo.h" +#include "RimWellLogFile.h" #include "RimWellLog.h" #include "RimWellLogPlot.h" #include "RimWellLogPlotTrace.h" @@ -82,9 +82,9 @@ void RicAddWellLogToPlotFeature::onActionTriggered(bool isChecked) RimWellPath* wellPath; wellLog->firstAnchestorOrThisOfType(wellPath); - RimWellLasFileInfo* lasFileInfo; - wellLog->firstAnchestorOrThisOfType(lasFileInfo); - if (lasFileInfo) + RimWellLogFile* wellLogFile; + wellLog->firstAnchestorOrThisOfType(wellLogFile); + if (wellLogFile) { size_t curveIdx = plotTrace->curveCount(); diff --git a/ApplicationCode/ProjectDataModel/CMakeLists_files.cmake b/ApplicationCode/ProjectDataModel/CMakeLists_files.cmake index 11b7a4f060..b4f4f32670 100644 --- a/ApplicationCode/ProjectDataModel/CMakeLists_files.cmake +++ b/ApplicationCode/ProjectDataModel/CMakeLists_files.cmake @@ -68,7 +68,7 @@ ${CEE_CURRENT_LIST_DIR}RimWellLogPlotCurve.h ${CEE_CURRENT_LIST_DIR}RimViewLinker.h ${CEE_CURRENT_LIST_DIR}RimViewLinkerCollection.h ${CEE_CURRENT_LIST_DIR}RimWellLogExtractionCurve.h -${CEE_CURRENT_LIST_DIR}RimWellLasFileInfo.h +${CEE_CURRENT_LIST_DIR}RimWellLogFile.h ${CEE_CURRENT_LIST_DIR}RimWellLog.h ${CEE_CURRENT_LIST_DIR}RimWellLogFileCurve.h ) @@ -137,7 +137,7 @@ ${CEE_CURRENT_LIST_DIR}RimWellLogPlotCurve.cpp ${CEE_CURRENT_LIST_DIR}RimViewLinker.cpp ${CEE_CURRENT_LIST_DIR}RimViewLinkerCollection.cpp ${CEE_CURRENT_LIST_DIR}RimWellLogExtractionCurve.cpp -${CEE_CURRENT_LIST_DIR}RimWellLasFileInfo.cpp +${CEE_CURRENT_LIST_DIR}RimWellLogFile.cpp ${CEE_CURRENT_LIST_DIR}RimWellLog.cpp ${CEE_CURRENT_LIST_DIR}RimWellLogFileCurve.cpp ) diff --git a/ApplicationCode/ProjectDataModel/RimWellLasFileInfo.cpp b/ApplicationCode/ProjectDataModel/RimWellLogFile.cpp similarity index 78% rename from ApplicationCode/ProjectDataModel/RimWellLasFileInfo.cpp rename to ApplicationCode/ProjectDataModel/RimWellLogFile.cpp index b68e79bdee..adeb04a3b9 100644 --- a/ApplicationCode/ProjectDataModel/RimWellLasFileInfo.cpp +++ b/ApplicationCode/ProjectDataModel/RimWellLogFile.cpp @@ -17,7 +17,7 @@ // ///////////////////////////////////////////////////////////////////////////////// -#include "RimWellLasFileInfo.h" +#include "RimWellLogFile.h" #include "RimWellLog.h" #include "RimWellPath.h" #include "RimWellPathCollection.h" @@ -28,12 +28,12 @@ #include -CAF_PDM_SOURCE_INIT(RimWellLasFileInfo, "WellLasFileInfo"); +CAF_PDM_SOURCE_INIT(RimWellLogFile, "WellLogFile"); //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RimWellLasFileInfo::RimWellLasFileInfo() +RimWellLogFile::RimWellLogFile() { CAF_PDM_InitObject("Well LAS File Info", "", "", ""); @@ -50,24 +50,24 @@ RimWellLasFileInfo::RimWellLasFileInfo() m_name.uiCapability()->setUiHidden(true); m_name.xmlCapability()->setIOWritable(false); - CAF_PDM_InitFieldNoDefault(&m_lasFileLogs, "WellLASFileLogs", "", "", "", ""); - m_lasFileLogs.uiCapability()->setUiHidden(true); - m_lasFileLogs.xmlCapability()->setIOWritable(false); + CAF_PDM_InitFieldNoDefault(&m_wellLogChannelNames, "WellLogChannelNames", "", "", "", ""); + m_wellLogChannelNames.uiCapability()->setUiHidden(true); + m_wellLogChannelNames.xmlCapability()->setIOWritable(false); - m_wellLogFile = NULL; + m_wellLogDataFile = NULL; } //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RimWellLasFileInfo::~RimWellLasFileInfo() +RimWellLogFile::~RimWellLogFile() { } //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimWellLasFileInfo::setFileName(const QString& fileName) +void RimWellLogFile::setFileName(const QString& fileName) { m_fileName = fileName; } @@ -75,29 +75,29 @@ void RimWellLasFileInfo::setFileName(const QString& fileName) //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -bool RimWellLasFileInfo::readFile() +bool RimWellLogFile::readFile() { - if (!m_wellLogFile.p()) + if (!m_wellLogDataFile.p()) { - m_wellLogFile = new RigWellLogFile; + m_wellLogDataFile = new RigWellLogFile; } - if (!m_wellLogFile->open(m_fileName)) + if (!m_wellLogDataFile->open(m_fileName)) { return false; } - m_wellName = m_wellLogFile->wellName(); + m_wellName = m_wellLogDataFile->wellName(); m_name = QFileInfo(m_fileName).fileName(); - m_lasFileLogs.deleteAllChildObjects(); + m_wellLogChannelNames.deleteAllChildObjects(); - QStringList wellLogNames = m_wellLogFile->wellLogNames(); + QStringList wellLogNames = m_wellLogDataFile->wellLogNames(); for (int logIdx = 0; logIdx < wellLogNames.size(); logIdx++) { RimWellLog* wellLog = new RimWellLog(); wellLog->setName(wellLogNames[logIdx]); - m_lasFileLogs.push_back(wellLog); + m_wellLogChannelNames.push_back(wellLog); } RimWellPath* wellPath; @@ -116,7 +116,7 @@ bool RimWellLasFileInfo::readFile() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -QString RimWellLasFileInfo::wellName() const +QString RimWellLogFile::wellName() const { return m_wellName; } diff --git a/ApplicationCode/ProjectDataModel/RimWellLasFileInfo.h b/ApplicationCode/ProjectDataModel/RimWellLogFile.h similarity index 80% rename from ApplicationCode/ProjectDataModel/RimWellLasFileInfo.h rename to ApplicationCode/ProjectDataModel/RimWellLogFile.h index 7cb1cb3e53..b10dcc7c2c 100644 --- a/ApplicationCode/ProjectDataModel/RimWellLasFileInfo.h +++ b/ApplicationCode/ProjectDataModel/RimWellLogFile.h @@ -35,13 +35,13 @@ class QString; /// /// //================================================================================================== -class RimWellLasFileInfo : public caf::PdmObject +class RimWellLogFile : public caf::PdmObject { CAF_PDM_HEADER_INIT; public: - RimWellLasFileInfo(); - virtual ~RimWellLasFileInfo(); + RimWellLogFile(); + virtual ~RimWellLogFile(); void setFileName(const QString& fileName); bool readFile(); @@ -49,15 +49,15 @@ public: QString wellName() const; virtual caf::PdmFieldHandle* userDescriptionField() { return &m_name; } - RigWellLogFile* wellLogFile() { return m_wellLogFile.p(); } + RigWellLogFile* wellLogFile() { return m_wellLogDataFile.p(); } - const caf::PdmChildArrayField* lasFileLogs() const { return &m_lasFileLogs; } + const caf::PdmChildArrayField* wellLogChannelNames() const { return &m_wellLogChannelNames; } private: - caf::PdmChildArrayField m_lasFileLogs; + caf::PdmChildArrayField m_wellLogChannelNames; private: - cvf::ref m_wellLogFile; + cvf::ref m_wellLogDataFile; caf::PdmField m_wellName; caf::PdmField m_fileName; caf::PdmField m_name; diff --git a/ApplicationCode/ProjectDataModel/RimWellLogFileCurve.cpp b/ApplicationCode/ProjectDataModel/RimWellLogFileCurve.cpp index 23a531cad5..aa1ed3578c 100644 --- a/ApplicationCode/ProjectDataModel/RimWellLogFileCurve.cpp +++ b/ApplicationCode/ProjectDataModel/RimWellLogFileCurve.cpp @@ -24,7 +24,7 @@ #include "RimWellPathCollection.h" #include "RimWellPath.h" #include "RimWellLog.h" -#include "RimWellLasFileInfo.h" +#include "RimWellLogFile.h" #include "RimWellLogPlotTrace.h" #include "RimWellLogPlot.h" @@ -72,7 +72,7 @@ void RimWellLogFileCurve::updatePlotData() { if (m_wellPath) { - RimWellLasFileInfo* logFileInfo = m_wellPath->m_lasFileInfo; + RimWellLogFile* logFileInfo = m_wellPath->m_wellLogFile; if (logFileInfo) { RigWellLogFile* wellLogFile = logFileInfo->wellLogFile(); @@ -193,10 +193,10 @@ QList RimWellLogFileCurve::calculateValueOptions(const c { if (m_wellPath()) { - RimWellLasFileInfo* lasFileInfo = m_wellPath->m_lasFileInfo(); - if (lasFileInfo) + RimWellLogFile* wellLogFile = m_wellPath->m_wellLogFile(); + if (wellLogFile) { - const caf::PdmChildArrayField* fileLogs = lasFileInfo->lasFileLogs(); + const caf::PdmChildArrayField* fileLogs = wellLogFile->wellLogChannelNames(); for (size_t i = 0; i < fileLogs->size(); i++) { diff --git a/ApplicationCode/ProjectDataModel/RimWellPath.cpp b/ApplicationCode/ProjectDataModel/RimWellPath.cpp index 813b6ec15f..e10ff59f3e 100644 --- a/ApplicationCode/ProjectDataModel/RimWellPath.cpp +++ b/ApplicationCode/ProjectDataModel/RimWellPath.cpp @@ -23,7 +23,7 @@ #include "RifJsonEncodeDecode.h" #include "RimProject.h" #include "RimTools.h" -#include "RimWellLasFileInfo.h" +#include "RimWellLogFile.h" #include "RimWellPathCollection.h" #include "RivWellPathPartMgr.h" @@ -82,8 +82,8 @@ RimWellPath::RimWellPath() CAF_PDM_InitField(&wellPathRadiusScaleFactor, "WellPathRadiusScale", 1.0, "Well path radius scale", "", "", ""); CAF_PDM_InitField(&wellPathColor, "WellPathColor", cvf::Color3f(0.999f, 0.333f, 0.999f), "Well path color", "", "", ""); - CAF_PDM_InitFieldNoDefault(&m_lasFileInfo, "LasFileInfo", "Las File Info", "", "", ""); - m_lasFileInfo.uiCapability()->setUiHidden(true); + CAF_PDM_InitFieldNoDefault(&m_wellLogFile, "WellLogFile", "Well Log File", "", "", ""); + m_wellLogFile.uiCapability()->setUiHidden(true); m_wellPath = NULL; m_project = NULL; @@ -95,9 +95,9 @@ RimWellPath::RimWellPath() //-------------------------------------------------------------------------------------------------- RimWellPath::~RimWellPath() { - if (m_lasFileInfo()) + if (m_wellLogFile()) { - delete m_lasFileInfo; + delete m_wellLogFile; } } @@ -175,24 +175,24 @@ void RimWellPath::readWellPathFile() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -RimWellLasFileInfo* RimWellPath::readWellLogFile(const QString& logFilePath) +RimWellLogFile* RimWellPath::readWellLogFile(const QString& logFilePath) { QFileInfo fi(logFilePath); - RimWellLasFileInfo* lasFileInfo = NULL; + RimWellLogFile* wellLogFile = NULL; if (fi.suffix().compare("las") == 0) { - lasFileInfo = new RimWellLasFileInfo(); - lasFileInfo->setFileName(logFilePath); - if (!lasFileInfo->readFile()) + wellLogFile = new RimWellLogFile(); + wellLogFile->setFileName(logFilePath); + if (!wellLogFile->readFile()) { - delete lasFileInfo; - lasFileInfo = NULL; + delete wellLogFile; + wellLogFile = NULL; } } - return lasFileInfo; + return wellLogFile; } //-------------------------------------------------------------------------------------------------- @@ -356,15 +356,15 @@ void RimWellPath::updateFilePathsFromProjectPath() //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -void RimWellPath::setLogFileInfo(RimWellLasFileInfo* logFileInfo) +void RimWellPath::setLogFileInfo(RimWellLogFile* logFileInfo) { - if (m_lasFileInfo()) + if (m_wellLogFile()) { - delete m_lasFileInfo; + delete m_wellLogFile; } - m_lasFileInfo = logFileInfo; - m_lasFileInfo->uiCapability()->setUiHidden(true); + m_wellLogFile = logFileInfo; + m_wellLogFile->uiCapability()->setUiHidden(true); - this->name = m_lasFileInfo->wellName(); + this->name = m_wellLogFile->wellName(); } diff --git a/ApplicationCode/ProjectDataModel/RimWellPath.h b/ApplicationCode/ProjectDataModel/RimWellPath.h index edddc4d985..ed08bc035f 100644 --- a/ApplicationCode/ProjectDataModel/RimWellPath.h +++ b/ApplicationCode/ProjectDataModel/RimWellPath.h @@ -34,7 +34,7 @@ class RimProject; class RivWellPathPartMgr; class RimWellPathCollection; -class RimWellLasFileInfo; +class RimWellLogFile; //================================================================================================== /// @@ -50,7 +50,7 @@ public: void setProject(RimProject* project) { m_project = project; } void setCollection(RimWellPathCollection* collection) { m_wellPathCollection = collection; } - void setLogFileInfo(RimWellLasFileInfo* logFileInfo); + void setLogFileInfo(RimWellLogFile* logFileInfo); virtual caf::PdmFieldHandle* userDescriptionField(); virtual caf::PdmFieldHandle* objectToggleField(); @@ -68,13 +68,13 @@ public: caf::PdmField wellPathColor; caf::PdmField wellPathRadiusScaleFactor; - caf::PdmChildField m_lasFileInfo; + caf::PdmChildField m_wellLogFile; RigWellPath* wellPathGeometry() { return m_wellPath.p(); } RivWellPathPartMgr* partMgr(); void readWellPathFile(); - static RimWellLasFileInfo* readWellLogFile(const QString& logFilePath); + static RimWellLogFile* readWellLogFile(const QString& logFilePath); void updateFilePathsFromProjectPath(); diff --git a/ApplicationCode/ProjectDataModel/RimWellPathCollection.cpp b/ApplicationCode/ProjectDataModel/RimWellPathCollection.cpp index 522a40fa90..f636caa108 100644 --- a/ApplicationCode/ProjectDataModel/RimWellPathCollection.cpp +++ b/ApplicationCode/ProjectDataModel/RimWellPathCollection.cpp @@ -24,7 +24,7 @@ #include "RiaPreferences.h" #include "RimProject.h" #include "RimWellPath.h" -#include "RimWellLasFileInfo.h" +#include "RimWellLogFile.h" #include "RivWellPathCollectionPartMgr.h" #include "cafPdmUiEditorHandle.h" @@ -132,9 +132,9 @@ void RimWellPathCollection::readWellPathFiles() wellPaths[wpIdx]->readWellPathFile(); } - if (wellPaths[wpIdx]->m_lasFileInfo) + if (wellPaths[wpIdx]->m_wellLogFile) { - wellPaths[wpIdx]->m_lasFileInfo->readFile(); + wellPaths[wpIdx]->m_wellLogFile->readFile(); } progress.setProgressDescription(QString("Reading file %1").arg(wellPaths[wpIdx]->name)); @@ -244,7 +244,7 @@ void RimWellPathCollection::addWellLogs(const QStringList& filePaths) { foreach (QString filePath, filePaths) { - RimWellLasFileInfo* logFileInfo = RimWellPath::readWellLogFile(filePath); + RimWellLogFile* logFileInfo = RimWellPath::readWellLogFile(filePath); if (logFileInfo) { RimWellPath* wellPath = wellPathByName(logFileInfo->wellName());