Added more clang-tidy checks

Improved GitHub Action to run clang-format as part of clang-tidy

* Simplify clang-tidy workflow
* Added modernize-use-using, modernize-redundant-void-arg, readability-static-accessed-through-instance
* Add nolint for libecl typedefs
This commit is contained in:
Magne Sjaastad 2023-04-14 14:07:45 +02:00 committed by GitHub
parent 457dc9080f
commit 6f6dc80bc6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
118 changed files with 220 additions and 225 deletions

View File

@ -1,6 +1,9 @@
name: clang-tidy
on:
push:
paths:
- '**.clang-tidy'
workflow_dispatch:
schedule:
# Once every night
@ -34,6 +37,7 @@ jobs:
run: |
sudo apt-get update --option="APT::Acquire::Retries=3"
sudo apt-get install --option="APT::Acquire::Retries=3" libxkbcommon-x11-0 libgl1-mesa-dev mesa-common-dev libglfw3-dev libglu1-mesa-dev libhdf5-dev
sudo apt-get install clang-tidy-15 clang-format-15
- name: Install Qt
uses: jurplel/install-qt-action@v3
@ -56,29 +60,16 @@ jobs:
mkdir build
cd build
cmake -DCMAKE_TOOLCHAIN_FILE=${{ matrix.config.cmake-toolchain }} -DRESINSIGHT_USE_OPENMP=OFF -DCMAKE_EXPORT_COMPILE_COMMANDS=ON ..
sudo apt-get install clang-tidy-15
mv compile_commands.json compile_commands_original.json
python ../scripts/fix_json_database.py compile_commands_original.json >> compile_commands.json
- name: clang-tidy on ApplicationLibCode/Application
- name: Run clang-tidy and apply fixes, clang-format after fixes
run: |
cd build
run-clang-tidy-15 -fix files ApplicationLibCode/Application
- name: clang-tidy on ApplicationLibCode/ProjectDataModel
run-clang-tidy-15 -fix files ApplicationLibCode/Application ApplicationLibCode/ProjectDataModel ApplicationLibCode/ReservoirDataModel ApplicationLibCode/Commands ApplicationLibCode/GeoMech
- name: Run clang-format after clang-tidy
run: |
cd build
run-clang-tidy-15 -fix files ApplicationLibCode/ProjectDataModel
- name: clang-tidy on ApplicationLibCode/ReservoirDataModel
run: |
cd build
run-clang-tidy-15 -fix files ApplicationLibCode/ReservoirDataModel
- name: clang-tidy on ApplicationLibCode/Commands
run: |
cd build
run-clang-tidy-15 -fix files ApplicationLibCode/Commands
- name: clang-tidy on ApplicationLibCode/GeoMech
run: |
cd build
run-clang-tidy-15 -fix files ApplicationLibCode/GeoMech
cd build/ApplicationLibCode
find -name '*.h' -o -name '*.cpp' -o -name '*.inl' | xargs clang-format-15 -i
- name: Remove Qt before creating PR
run: |
rm -rf Qt

View File

@ -1,5 +1,5 @@
---
Checks: '-*,modernize-use-override,modernize-deprecated-headers,bugprone-bool-pointer-implicit-conversion,bugprone-parent-virtual-call,bugprone-redundant-branch-condition,bugprone-suspicious-semicolon,bugprone-suspicious-string-compare'
Checks: '-*,modernize-use-override,modernize-deprecated-headers,modernize-use-using,bugprone-bool-pointer-implicit-conversion,bugprone-parent-virtual-call,bugprone-redundant-branch-condition,bugprone-suspicious-semicolon,bugprone-suspicious-string-compare,modernize-redundant-void-arg,readability-static-accessed-through-instance'
WarningsAsErrors: ''
HeaderFilterRegex: 'ApplicationLibCode/*.*$'
FormatStyle: 'file'

View File

@ -29,7 +29,7 @@
class RiaColorTables
{
public:
typedef std::map<RiaDefines::WellPathComponentType, cvf::Color3::ColorIdent> WellPathComponentColors;
using WellPathComponentColors = std::map<RiaDefines::WellPathComponentType, cvf::Color3::ColorIdent>;
static const caf::ColorTable& normalPaletteColors();
static const caf::ColorTable& normalPaletteOppositeOrderingColors();

View File

@ -34,7 +34,7 @@ class QDateTime;
class RiaCurveDataTools
{
public:
typedef std::vector<std::pair<size_t, size_t>> CurveIntervals;
using CurveIntervals = std::vector<std::pair<size_t, size_t>>;
enum class ErrorAxis
{

View File

@ -38,7 +38,7 @@ template <typename XValueType>
class RiaCurveMerger
{
public:
typedef XValueComparator<XValueType> XComparator;
using XComparator = XValueComparator<XValueType>;
RiaCurveMerger();
void addCurveData( const std::vector<XValueType>& xValues, const std::vector<double>& yValues );
@ -78,7 +78,7 @@ private:
std::vector<std::vector<double>> m_interpolatedValuesForAllCurves;
};
typedef RiaCurveMerger<time_t> RiaTimeHistoryCurveMerger;
using RiaTimeHistoryCurveMerger = RiaCurveMerger<time_t>;
template <>
bool XValueComparator<double>::equals( const double& lhs, const double& rhs );

View File

@ -21,14 +21,14 @@
#include <fstream>
#include <iostream>
RiaImageCompareReporter::RiaImageCompareReporter( void )
RiaImageCompareReporter::RiaImageCompareReporter()
{
m_showOriginal = true;
m_showGenerated = true;
m_showInteractiveDiff = false;
}
RiaImageCompareReporter::~RiaImageCompareReporter( void )
RiaImageCompareReporter::~RiaImageCompareReporter()
{
}

View File

@ -33,7 +33,7 @@ class RifReaderSettings;
class RiaImportEclipseCaseTools
{
public:
typedef std::map<QString, int> FileCaseIdMap;
using FileCaseIdMap = std::map<QString, int>;
static bool openEclipseCasesFromFile( const QStringList& fileNames,
bool createView,

View File

@ -45,7 +45,7 @@ public:
LGRS
};
typedef caf::AppEnum<ExportType> ExportTypeEnum;
using ExportTypeEnum = caf::AppEnum<ExportType>;
public:
RicfCommandFileExecutor();

View File

@ -56,7 +56,7 @@ void RicExitApplicationFeature::onActionTriggered( bool isChecked )
}
// Hide all windows first to make sure they get closed properly
for ( QWidget* topLevelWidget : app->topLevelWidgets() )
for ( QWidget* topLevelWidget : RiaGuiApplication::topLevelWidgets() )
{
topLevelWidget->hide();
}

View File

@ -40,7 +40,7 @@ public:
SPLIT_ON_WELL,
SPLIT_ON_WELL_AND_COMPLETION_TYPE,
};
typedef caf::AppEnum<ExportSplit> ExportSplitType;
using ExportSplitType = caf::AppEnum<ExportSplit>;
// Exported in .proto file. Do not change without changing .proto
enum class CompdatExport
@ -48,7 +48,7 @@ public:
TRANSMISSIBILITIES,
WPIMULT_AND_DEFAULT_CONNECTION_FACTORS,
};
typedef caf::AppEnum<CompdatExport> CompdatExportType;
using CompdatExportType = caf::AppEnum<CompdatExport>;
// Exported in .proto file. Do not change without changing .proto
enum class CombinationMode
@ -56,9 +56,9 @@ public:
INDIVIDUALLY,
COMBINED,
};
typedef caf::AppEnum<CombinationMode> CombinationModeType;
using CombinationModeType = caf::AppEnum<CombinationMode>;
typedef caf::AppEnum<RicExportFractureCompletionsImpl::PressureDepletionWBHPSource> TransScalingWBHPSource;
using TransScalingWBHPSource = caf::AppEnum<RicExportFractureCompletionsImpl::PressureDepletionWBHPSource>;
RicExportCompletionDataSettingsUi();

View File

@ -1099,7 +1099,7 @@ void RicWellPathExportCompletionDataFeatureImpl::exportWpimultTableUsingFormatte
for ( auto& completion : completionData )
{
if ( completion.wpimult() == 0.0 || completion.isDefaultValue( completion.wpimult() ) )
if ( completion.wpimult() == 0.0 || RigCompletionData::isDefaultValue( completion.wpimult() ) )
{
continue;
}

View File

@ -52,7 +52,7 @@ class SubSegmentIntersectionInfo;
//==================================================================================================
///
//==================================================================================================
typedef std::shared_ptr<QFile> QFilePtr;
using QFilePtr = std::shared_ptr<QFile>;
class TransmissibilityData
{

View File

@ -411,7 +411,7 @@ QList<caf::PdmOptionItemInfo> RicExportEclipseSectorModelUi::calculateValueOptio
QList<caf::PdmOptionItemInfo> allOptions =
RimEclipseResultDefinition::calcOptionsForVariableUiFieldStandard( RiaDefines::ResultCatType::STATIC_NATIVE, resultData );
std::set<QString> mainKeywords = this->mainKeywords();
std::set<QString> mainKeywords = RicExportEclipseSectorModelUi::mainKeywords();
for ( const caf::PdmOptionItemInfo& option : allOptions )
{
if ( mainKeywords.count( option.optionUiText() ) )

View File

@ -35,8 +35,8 @@ class QTextStream;
//==================================================================================================
///
//==================================================================================================
typedef std::shared_ptr<QFile> QFilePtr;
typedef std::shared_ptr<QTextStream> QTextStreamPtr;
using QFilePtr = std::shared_ptr<QFile>;
using QTextStreamPtr = std::shared_ptr<QTextStream>;
//==================================================================================================
///

View File

@ -41,7 +41,7 @@ CAF_PDM_SOURCE_INIT( RicExportToLasFileObj, "RicExportToLasFileObj" );
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RicExportToLasFileObj::RicExportToLasFileObj( void )
RicExportToLasFileObj::RicExportToLasFileObj()
{
CAF_PDM_InitObject( "RicExportToLasFileObj" );
@ -53,7 +53,7 @@ CAF_PDM_SOURCE_INIT( RicExportToLasFileResampleUi, "RicExportToLasFileResampleUi
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RicExportToLasFileResampleUi::RicExportToLasFileResampleUi( void )
RicExportToLasFileResampleUi::RicExportToLasFileResampleUi()
: m_enableCurveUnitConversion( false )
{
CAF_PDM_InitObject( "Resample LAS curves for export" );

View File

@ -31,7 +31,7 @@ class RicExportToLasFileObj : public caf::PdmObject
CAF_PDM_HEADER_INIT;
public:
RicExportToLasFileObj( void );
RicExportToLasFileObj();
caf::PdmField<QString> tvdrkbOffset;
};
@ -52,7 +52,7 @@ public:
using CurveUnitConversionEnum = caf::AppEnum<CurveUnitConversion>;
public:
RicExportToLasFileResampleUi( void );
RicExportToLasFileResampleUi();
~RicExportToLasFileResampleUi() override;
caf::PdmField<QString> exportFolder;

View File

@ -29,7 +29,7 @@ class RimWellPath;
//==================================================================================================
///
//==================================================================================================
typedef std::shared_ptr<QFile> QFilePtr;
using QFilePtr = std::shared_ptr<QFile>;
//==================================================================================================
///

View File

@ -32,5 +32,5 @@ enum SplitType
LGR_PER_WELL
};
typedef caf::AppEnum<SplitType> SplitTypeEnum;
using SplitTypeEnum = caf::AppEnum<SplitType>;
} // namespace Lgr

View File

@ -44,7 +44,7 @@ public:
bool getPacketsAsCombinedBuffer( const std::vector<int>& packetIdsToGet, QByteArray* combinedPacketArr ) const;
private:
typedef std::map<int, std::unique_ptr<VdeArrayDataPacket>> IdToPacketMap_T;
using IdToPacketMap_T = std::map<int, std::unique_ptr<VdeArrayDataPacket>>;
IdToPacketMap_T m_idToPacketMap;
};

View File

@ -417,7 +417,7 @@ QString VdeVizDataExtractor::createModelMetaJsonString( const std::vector<std::u
ResInsightInternalJson::Json jsonCodec;
const bool prettifyJson = true;
QString jsonStr = jsonCodec.encode( jsonModelMeta, prettifyJson );
QString jsonStr = ResInsightInternalJson::Json::encode( jsonModelMeta, prettifyJson );
return jsonStr;
}

View File

@ -74,8 +74,8 @@ inline uint128_t Uint128( uint64_t lo, uint64_t hi )
return lo + ( ( (uint128_t)hi ) << 64 );
}
#else
typedef std::pair<uint64_t, uint64_t> uint128_t;
inline uint64_t Uint128Low64( const uint128_t x )
using uint128_t = std::pair<uint64_t, uint64_t>;
inline uint64_t Uint128Low64( const uint128_t x )
{
return x.first;
}

View File

@ -118,7 +118,7 @@ void RicCreateTemporaryLgrFeature::updateViews( RimEclipseCase* eclipseCase )
guiApp = RiaGuiApplication::instance();
}
if ( guiApp ) guiApp->clearAllSelections();
if ( guiApp ) RiaGuiApplication::clearAllSelections();
deleteAllCachedData( eclipseCase );
RimMainPlotCollection::current()->deleteAllCachedData();

View File

@ -65,9 +65,9 @@ void RicThemeColorEditorFeature::onActionTriggered( bool isChecked )
QComboBox* themeSelector = new QComboBox();
caf::AppEnum<RiaDefines::ThemeEnum> themes;
for ( size_t index = 0; index < themes.size(); index++ )
for ( size_t index = 0; index < caf::AppEnum<RiaDefines::ThemeEnum>::size(); index++ )
{
themeSelector->addItem( themes.uiTextFromIndex( index ), QVariant::fromValue( index ) );
themeSelector->addItem( caf::AppEnum<RiaDefines::ThemeEnum>::uiTextFromIndex( index ), QVariant::fromValue( index ) );
if ( static_cast<RiaDefines::ThemeEnum>( index ) == theme )
{
themeSelector->setCurrentIndex( static_cast<int>( index ) );

View File

@ -234,7 +234,7 @@ void RiuWellImportWizard::httpFinished()
{
// Write out the content without leading/trailing []
file.close();
file.remove( singleWellPathFilePath );
QFile::remove( singleWellPathFilePath );
if ( file.open( QFile::WriteOnly ) )
{

View File

@ -91,7 +91,7 @@ public:
DECIMAL_DOT,
};
typedef caf::AppEnum<DecimalSeparator> DecimalSeparatorEnum;
using DecimalSeparatorEnum = caf::AppEnum<DecimalSeparator>;
enum DateFormat
{
@ -105,7 +105,7 @@ public:
DATE_MMDDYY_SLASH_SEPARATED
};
typedef caf::AppEnum<DateFormat> DateFormatEnum;
using DateFormatEnum = caf::AppEnum<DateFormat>;
enum TimeFormat
{
@ -115,7 +115,7 @@ public:
TIME_HHMMSSZZZ,
};
typedef caf::AppEnum<TimeFormat> TimeFormatEnum;
using TimeFormatEnum = caf::AppEnum<TimeFormat>;
enum CellSeparator
{
@ -124,7 +124,7 @@ public:
CELL_SEMICOLON
};
typedef caf::AppEnum<CellSeparator> CellSeparatorEnum;
using CellSeparatorEnum = caf::AppEnum<CellSeparator>;
public:
RicPasteAsciiDataToSummaryPlotFeatureUi();

View File

@ -59,7 +59,7 @@ public:
static const QString CONFIGURATION_NAME;
private:
typedef caf::AppEnum<RimSummaryCurveAppearanceCalculator::CurveAppearanceType> AppearanceTypeAppEnum;
using AppearanceTypeAppEnum = caf::AppEnum<RimSummaryCurveAppearanceCalculator::CurveAppearanceType>;
public:
RicSummaryPlotEditorUi();

View File

@ -35,7 +35,7 @@ class RicLinkVisibleViewsFeatureUi : public caf::PdmObject
CAF_PDM_HEADER_INIT;
public:
RicLinkVisibleViewsFeatureUi( void );
RicLinkVisibleViewsFeatureUi();
void setViews( const std::vector<Rim3dView*>& allViews );
Rim3dView* masterView();

View File

@ -32,7 +32,7 @@
#include <vector>
typedef struct ecl_file_struct ecl_file_type;
using ecl_file_type = struct ecl_file_struct;
class RifEclipseRestartDataAccess;
class QByteArray;

View File

@ -39,10 +39,12 @@ class QDateTime;
struct RigWellResultPoint;
// NOLINTBEGIN(modernize-use-using)
typedef struct ecl_grid_struct ecl_grid_type;
typedef struct ecl_file_struct ecl_file_type;
typedef struct well_conn_struct well_conn_type;
typedef struct well_segment_struct well_segment_type;
// NOLINTEND(modernize-use-using)
//==================================================================================================
//

View File

@ -62,8 +62,10 @@ private:
int indexFromAddress( const RifEclipseRftAddress& rftAddress ) const;
private:
// NOLINTBEGIN(modernize-use-using)
// Taken from ecl_rft_file.h and ecl_rft_node.h
typedef struct ecl_rft_file_struct ecl_rft_file_type;
// NOLINTEND(modernize-use-using)
QString m_fileName;
ecl_rft_file_type* m_ecl_rft_file;

View File

@ -87,8 +87,8 @@ public:
void load();
private:
typedef std::pair<const QString, WellObservationSet> WellObservationPair;
typedef std::map<QString, WellObservationSet> WellObservationMap;
using WellObservationPair = std::pair<const QString, WellObservationSet>;
using WellObservationMap = std::map<QString, WellObservationSet>;
WellObservationMap loadWellDates( QDir& dir, QString* errorMsg );
static bool readTxtFile( const QString& txtFileName, QString* errorMsg, WellObservationSet* wellObservationSet );

View File

@ -194,7 +194,7 @@ void findReferenceElementForNode( const RigFemPart& part, size_t nodeIdx, size_t
if ( nodeToIntersectionDistance < refElement->intersectionPointToCurrentNodeDistance )
{
cvf::ubyte faceNodes[4];
grid->cellFaceVertexIndices( intersection.m_face, faceNodes );
RigFemPartGrid::cellFaceVertexIndices( intersection.m_face, faceNodes );
std::vector<size_t> topFaceCoords(
{ nodeIndices[faceNodes[0]], nodeIndices[faceNodes[1]], nodeIndices[faceNodes[2]], nodeIndices[faceNodes[3]] } );

View File

@ -45,7 +45,7 @@ class Rim3dWellLogCurve;
class Riv3dWellLogCurveGeometryGenerator : public cvf::Object
{
public:
typedef std::pair<cvf::Vec3d, double> PointValuePair;
using PointValuePair = std::pair<cvf::Vec3d, double>;
Riv3dWellLogCurveGeometryGenerator( RimWellPath* wellPath );
void createCurveDrawables( gsl::not_null<const caf::DisplayCoordTransform*> displayCoordTransform,

View File

@ -67,7 +67,7 @@ public:
ABS_OTHER_VALUE,
TIME_STEP,
};
typedef caf::AppEnum<SortGroupType> SortGroupAppEnum;
using SortGroupAppEnum = caf::AppEnum<SortGroupType>;
using TimeStepFilterEnum = caf::AppEnum<RimTimeStepFilter::TimeStepFilterTypeEnum>;

View File

@ -76,8 +76,8 @@ class RimFracture : public RimCheckableNamedObject, public Rim3dPropertiesInterf
CAF_PDM_HEADER_INIT;
public:
RimFracture( void );
~RimFracture( void ) override;
RimFracture();
~RimFracture() override;
double perforationLength() const;
double perforationEfficiency() const;

View File

@ -39,7 +39,7 @@ CAF_PDM_SOURCE_INIT( RimSimWellFracture, "SimWellFracture" );
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimSimWellFracture::RimSimWellFracture( void )
RimSimWellFracture::RimSimWellFracture()
{
CAF_PDM_InitObject( "SimWellFracture", ":/FractureSymbol16x16.png" );

View File

@ -32,8 +32,8 @@ class RimSimWellFracture : public RimFracture
CAF_PDM_HEADER_INIT;
public:
RimSimWellFracture( void );
~RimSimWellFracture( void ) override;
RimSimWellFracture();
~RimSimWellFracture() override;
void setClosestWellCoord( cvf::Vec3d& position, size_t branchIndex );

View File

@ -26,7 +26,7 @@ CAF_PDM_SOURCE_INIT( RimSimWellFractureCollection, "SimWellFractureCollection" )
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimSimWellFractureCollection::RimSimWellFractureCollection( void )
RimSimWellFractureCollection::RimSimWellFractureCollection()
{
CAF_PDM_InitObject( "Fractures", ":/FractureLayout16x16.png" );

View File

@ -33,8 +33,8 @@ class RimSimWellFractureCollection : public caf::PdmObject
CAF_PDM_HEADER_INIT;
public:
RimSimWellFractureCollection( void );
~RimSimWellFractureCollection( void ) override;
RimSimWellFractureCollection();
~RimSimWellFractureCollection() override;
caf::PdmChildArrayField<RimSimWellFracture*> simwellFractures;

View File

@ -55,7 +55,7 @@ protected:
void defineUiTreeOrdering( caf::PdmUiTreeOrdering& uiTreeOrdering, QString uiConfigName = "" ) override;
private:
typedef caf::AppEnum<RiaDefines::WellPathComponentType> CompletionTypeEnum;
using CompletionTypeEnum = caf::AppEnum<RiaDefines::WellPathComponentType>;
caf::PdmField<caf::AppEnum<RiaDefines::EclipseUnitSystem>> m_valveTemplateUnit;

View File

@ -36,7 +36,7 @@ public:
WATER,
LIQUID
};
typedef caf::AppEnum<WellType> WellTypeEnum;
using WellTypeEnum = caf::AppEnum<WellType>;
enum GasInflowEquation
{
@ -45,21 +45,21 @@ public:
DRY_GAS_PSEUDO_PRESSURE,
GENERALIZED_PSEUDO_PRESSURE
};
typedef caf::AppEnum<GasInflowEquation> GasInflowEnum;
using GasInflowEnum = caf::AppEnum<GasInflowEquation>;
enum AutomaticWellShutIn
{
ISOLATE_FROM_FORMATION,
STOP_ABOVE_FORMATION
};
typedef caf::AppEnum<AutomaticWellShutIn> AutomaticWellShutInEnum;
using AutomaticWellShutInEnum = caf::AppEnum<AutomaticWellShutIn>;
enum HydrostaticDensity
{
SEGMENTED,
AVERAGED
};
typedef caf::AppEnum<HydrostaticDensity> HydrostaticDensityEnum;
using HydrostaticDensityEnum = caf::AppEnum<HydrostaticDensity>;
public:
RimWellPathCompletionSettings();

View File

@ -33,7 +33,7 @@ CAF_PDM_SOURCE_INIT( RimWellPathFracture, "WellPathFracture" );
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimWellPathFracture::RimWellPathFracture( void )
RimWellPathFracture::RimWellPathFracture()
{
CAF_PDM_InitObject( "Fracture", ":/FractureSymbol16x16.png" );

View File

@ -36,8 +36,8 @@ class RimWellPathFracture : public RimFracture
CAF_PDM_HEADER_INIT;
public:
RimWellPathFracture( void );
~RimWellPathFracture( void ) override;
RimWellPathFracture();
~RimWellPathFracture() override;
double fractureMD() const override;
void setMeasuredDepth( double mdValue );

View File

@ -28,7 +28,7 @@ CAF_PDM_SOURCE_INIT( RimWellPathFractureCollection, "WellPathFractureCollection"
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimWellPathFractureCollection::RimWellPathFractureCollection( void )
RimWellPathFractureCollection::RimWellPathFractureCollection()
{
CAF_PDM_InitObject( "Fractures", ":/FractureLayout16x16.png" );

View File

@ -38,8 +38,8 @@ class RimWellPathFractureCollection : public RimCheckableNamedObject
CAF_PDM_HEADER_INIT;
public:
RimWellPathFractureCollection( void );
~RimWellPathFractureCollection( void ) override;
RimWellPathFractureCollection();
~RimWellPathFractureCollection() override;
bool hasFractures() const;
void addFracture( RimWellPathFracture* fracture );

View File

@ -69,7 +69,7 @@ QString RimFlowDiagSolution::addCrossFlowEnding( const QString& wellName )
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimFlowDiagSolution::RimFlowDiagSolution( void )
RimFlowDiagSolution::RimFlowDiagSolution()
{
CAF_PDM_InitObject( "Flow Diagnostics Solution" );
CAF_PDM_InitField( &m_userDescription, "UserDescription", QString( "All Wells" ), "Description" );
@ -78,7 +78,7 @@ RimFlowDiagSolution::RimFlowDiagSolution( void )
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimFlowDiagSolution::~RimFlowDiagSolution( void )
RimFlowDiagSolution::~RimFlowDiagSolution()
{
}

View File

@ -38,8 +38,8 @@ class RimWellRftEnsembleCurveSet : public caf::PdmObject
CAF_PDM_HEADER_INIT;
public:
typedef RimEnsembleCurveSetColorManager::ColorMode ColorMode;
typedef RimEnsembleCurveSetColorManager::ColorModeEnum ColorModeEnum;
using ColorMode = RimEnsembleCurveSetColorManager::ColorMode;
using ColorModeEnum = RimEnsembleCurveSetColorManager::ColorModeEnum;
public:
RimWellRftEnsembleCurveSet();

View File

@ -29,7 +29,7 @@ CAF_PDM_SOURCE_INIT( RimGeoMechCellColors, "GeoMechResultSlot" );
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimGeoMechCellColors::RimGeoMechCellColors( void )
RimGeoMechCellColors::RimGeoMechCellColors()
: legendConfigChanged( this )
{
CAF_PDM_InitFieldNoDefault( &legendConfig, "LegendDefinition", "Color Legend" );
@ -41,7 +41,7 @@ RimGeoMechCellColors::RimGeoMechCellColors( void )
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimGeoMechCellColors::~RimGeoMechCellColors( void )
RimGeoMechCellColors::~RimGeoMechCellColors()
{
delete legendConfig;
}

View File

@ -39,8 +39,8 @@ public:
caf::Signal<RimLegendConfigChangeType> legendConfigChanged;
public:
RimGeoMechCellColors( void );
~RimGeoMechCellColors( void ) override;
RimGeoMechCellColors();
~RimGeoMechCellColors() override;
caf::PdmChildField<RimRegularLegendConfig*> legendConfig;

View File

@ -58,7 +58,7 @@ public:
double sampleSpacing() const override;
protected:
typedef RimContourMapProjection::CellIndexAndResult CellIndexAndResult;
using CellIndexAndResult = RimContourMapProjection::CellIndexAndResult;
// GeoMech implementation specific data generation methods
cvf::ref<cvf::UByteArray> getCellVisibility() const override;

View File

@ -301,7 +301,7 @@ void RimGeoMechContourMapView::appendContourMapProjectionToModel()
if ( frameScene )
{
cvf::String name = "ContourMapProjection";
this->removeModelByName( frameScene, name );
RimGeoMechContourMapView::removeModelByName( frameScene, name );
cvf::ref<cvf::ModelBasicList> contourMapProjectionModelBasicList = new cvf::ModelBasicList;
contourMapProjectionModelBasicList->setName( name );
@ -326,7 +326,7 @@ void RimGeoMechContourMapView::appendContourLinesToModel()
if ( frameScene )
{
cvf::String name = "ContourMapLines";
this->removeModelByName( frameScene, name );
RimGeoMechContourMapView::removeModelByName( frameScene, name );
cvf::ref<cvf::ModelBasicList> contourMapLabelModelBasicList = new cvf::ModelBasicList;
contourMapLabelModelBasicList->setName( name );
@ -351,7 +351,7 @@ void RimGeoMechContourMapView::appendPickPointVisToModel()
if ( frameScene )
{
cvf::String name = "ContourMapPickPoint";
this->removeModelByName( frameScene, name );
RimGeoMechContourMapView::removeModelByName( frameScene, name );
cvf::ref<cvf::ModelBasicList> contourMapProjectionModelBasicList = new cvf::ModelBasicList;
contourMapProjectionModelBasicList->setName( name );

View File

@ -32,7 +32,7 @@ CAF_PDM_SOURCE_INIT( RimGeoMechModels, "ResInsightGeoMechModels" );
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimGeoMechModels::RimGeoMechModels( void )
RimGeoMechModels::RimGeoMechModels()
{
CAF_PDM_InitObject( "Geomechanical Models", ":/GeoMechCases48x48.png" );
@ -43,7 +43,7 @@ RimGeoMechModels::RimGeoMechModels( void )
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimGeoMechModels::~RimGeoMechModels( void )
RimGeoMechModels::~RimGeoMechModels()
{
}

View File

@ -35,8 +35,8 @@ class RimGeoMechModels : public caf::PdmObject
CAF_PDM_HEADER_INIT;
public:
RimGeoMechModels( void );
~RimGeoMechModels( void ) override;
RimGeoMechModels();
~RimGeoMechModels() override;
RimGeoMechCase* copyCase( RimGeoMechCase* thecase, const QString& newInputFileName );
void removeCase( RimGeoMechCase* thecase );

View File

@ -74,7 +74,7 @@ CAF_PDM_SOURCE_INIT( RimGeoMechResultDefinition, "GeoMechResultDefinition" );
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimGeoMechResultDefinition::RimGeoMechResultDefinition( void )
RimGeoMechResultDefinition::RimGeoMechResultDefinition()
{
CAF_PDM_InitObject( "Color Result", ":/CellResult.png" );
@ -124,7 +124,7 @@ RimGeoMechResultDefinition::RimGeoMechResultDefinition( void )
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimGeoMechResultDefinition::~RimGeoMechResultDefinition( void )
RimGeoMechResultDefinition::~RimGeoMechResultDefinition()
{
}

View File

@ -46,8 +46,8 @@ class RimGeoMechResultDefinition : public RimFemResultObserver, public RimChecka
CAF_PDM_HEADER_INIT;
public:
RimGeoMechResultDefinition( void );
~RimGeoMechResultDefinition( void ) override;
RimGeoMechResultDefinition();
~RimGeoMechResultDefinition() override;
void setGeoMechCase( RimGeoMechCase* geomCase );
RimGeoMechCase* geoMechCase() const;

View File

@ -84,7 +84,7 @@ CAF_PDM_SOURCE_INIT( RimGeoMechView, "GeoMechView" );
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimGeoMechView::RimGeoMechView( void )
RimGeoMechView::RimGeoMechView()
: m_currentInternalTimeStep( 0 )
, m_currentDataFrameIndex( -1 )
{
@ -125,7 +125,7 @@ RimGeoMechView::RimGeoMechView( void )
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimGeoMechView::~RimGeoMechView( void )
RimGeoMechView::~RimGeoMechView()
{
m_geomechCase = nullptr;
@ -423,7 +423,7 @@ void RimGeoMechView::onUpdateDisplayModelForCurrentTimeStep()
{
// Grid model
cvf::String name = "GridModel";
this->removeModelByName( frameScene, name );
RimGeoMechView::removeModelByName( frameScene, name );
cvf::ref<cvf::ModelBasicList> frameParts = new cvf::ModelBasicList;
frameParts->setName( name );
@ -436,7 +436,7 @@ void RimGeoMechView::onUpdateDisplayModelForCurrentTimeStep()
// Well Paths
{
cvf::String name = "WellPathMod";
this->removeModelByName( frameScene, name );
RimGeoMechView::removeModelByName( frameScene, name );
cvf::ref<cvf::ModelBasicList> wellPathModelBasicList = new cvf::ModelBasicList;
wellPathModelBasicList->setName( name );
@ -450,7 +450,7 @@ void RimGeoMechView::onUpdateDisplayModelForCurrentTimeStep()
{
// Tensors
cvf::String name = "Tensor";
this->removeModelByName( frameScene, name );
RimGeoMechView::removeModelByName( frameScene, name );
cvf::ref<cvf::ModelBasicList> frameParts = new cvf::ModelBasicList;
frameParts->setName( name );

View File

@ -63,8 +63,8 @@ class RimGeoMechView : public RimGridView
CAF_PDM_HEADER_INIT;
public:
RimGeoMechView( void );
~RimGeoMechView( void ) override;
RimGeoMechView();
~RimGeoMechView() override;
RiaDefines::View3dContent viewContent() const override;

View File

@ -84,7 +84,7 @@ class RimGridCrossPlotDataSet : public RimCheckableNamedObject, public RimNameCo
CAF_PDM_HEADER_INIT;
public:
typedef caf::AppEnum<RigGridCrossPlotCurveGrouping> CurveGroupingEnum;
using CurveGroupingEnum = caf::AppEnum<RigGridCrossPlotCurveGrouping>;
enum NameComponents
{

View File

@ -62,7 +62,7 @@ const cvf::Mat4d Rim2dIntersectionView::sm_defaultViewMatrix = cvf::Mat4d( 1, 0,
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
Rim2dIntersectionView::Rim2dIntersectionView( void )
Rim2dIntersectionView::Rim2dIntersectionView()
{
CAF_PDM_InitObject( "Intersection View", ":/CrossSection16x16.png" );
@ -107,7 +107,7 @@ Rim2dIntersectionView::Rim2dIntersectionView( void )
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
Rim2dIntersectionView::~Rim2dIntersectionView( void )
Rim2dIntersectionView::~Rim2dIntersectionView()
{
}

View File

@ -45,8 +45,8 @@ class Rim2dIntersectionView : public Rim3dView
CAF_PDM_HEADER_INIT;
public:
Rim2dIntersectionView( void );
~Rim2dIntersectionView( void ) override;
Rim2dIntersectionView();
~Rim2dIntersectionView() override;
RiaDefines::View3dContent viewContent() const override;

View File

@ -71,7 +71,7 @@ public:
CUSTOM_PROPERTIES
};
typedef caf::AppEnum<RimCellEdgeColors::EdgeFaceType> EdgeFaceEnum;
using EdgeFaceEnum = caf::AppEnum<RimCellEdgeColors::EdgeFaceType>;
void setReservoirView( RimEclipseView* ownerReservoirView );

View File

@ -26,7 +26,7 @@ CAF_PDM_XML_ABSTRACT_SOURCE_INIT( RimCheckableNamedObject, "CheckableNamedObject
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimCheckableNamedObject::RimCheckableNamedObject( void )
RimCheckableNamedObject::RimCheckableNamedObject()
{
CAF_PDM_InitScriptableObject( "Checkable object" );
CAF_PDM_InitScriptableField( &m_isChecked, "IsChecked", true, "Active" );
@ -36,7 +36,7 @@ RimCheckableNamedObject::RimCheckableNamedObject( void )
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimCheckableNamedObject::~RimCheckableNamedObject( void )
RimCheckableNamedObject::~RimCheckableNamedObject()
{
}

View File

@ -29,8 +29,8 @@ class RimCheckableNamedObject : public RimNamedObject
CAF_PDM_HEADER_INIT;
public:
RimCheckableNamedObject( void );
~RimCheckableNamedObject( void ) override;
RimCheckableNamedObject();
~RimCheckableNamedObject() override;
bool isChecked() const;
void setCheckState( bool checkState );

View File

@ -23,7 +23,7 @@ CAF_PDM_XML_ABSTRACT_SOURCE_INIT( RimCheckableObject, "RimCheckableObject" ); //
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimCheckableObject::RimCheckableObject( void )
RimCheckableObject::RimCheckableObject()
{
CAF_PDM_InitField( &m_isChecked, "IsChecked", true, "Active" );
m_isChecked.uiCapability()->setUiHidden( true );
@ -32,7 +32,7 @@ RimCheckableObject::RimCheckableObject( void )
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimCheckableObject::~RimCheckableObject( void )
RimCheckableObject::~RimCheckableObject()
{
}

View File

@ -30,8 +30,8 @@ class RimCheckableObject : public caf::PdmObject
CAF_PDM_HEADER_INIT;
public:
RimCheckableObject( void );
~RimCheckableObject( void ) override;
RimCheckableObject();
~RimCheckableObject() override;
bool isChecked() const;
void setCheckState( bool checkState );

View File

@ -45,7 +45,7 @@ class RimContourMapProjection : public RimCheckableNamedObject
CAF_PDM_HEADER_INIT;
public:
typedef std::pair<size_t, double> CellIndexAndResult;
using CellIndexAndResult = std::pair<size_t, double>;
struct ContourPolygon
{
@ -69,8 +69,8 @@ public:
RESULTS_GAS_COLUMN,
RESULTS_HC_COLUMN
};
typedef caf::AppEnum<ResultAggregationEnum> ResultAggregation;
typedef std::vector<ContourPolygon> ContourPolygons;
using ResultAggregation = caf::AppEnum<ResultAggregationEnum>;
using ContourPolygons = std::vector<ContourPolygon>;
RimContourMapProjection();
~RimContourMapProjection() override;

View File

@ -69,7 +69,7 @@ public:
AXIS_GRID_MAJOR_AND_MINOR = 0x03
};
typedef caf::AppEnum<AxisGridVisibility> AxisGridEnum;
using AxisGridEnum = caf::AppEnum<AxisGridVisibility>;
using DepthTypeEnum = RiaDefines::DepthTypeEnum;
enum class DepthOrientation_OBSOLETE

View File

@ -39,7 +39,7 @@ CAF_PDM_SOURCE_INIT( RimEclipseCaseCollection, "ResInsightAnalysisModels" );
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimEclipseCaseCollection::RimEclipseCaseCollection( void )
RimEclipseCaseCollection::RimEclipseCaseCollection()
{
CAF_PDM_InitObject( "Grid Models", ":/Cases16x16.png" );
@ -55,7 +55,7 @@ RimEclipseCaseCollection::RimEclipseCaseCollection( void )
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimEclipseCaseCollection::~RimEclipseCaseCollection( void )
RimEclipseCaseCollection::~RimEclipseCaseCollection()
{
close();
}

View File

@ -43,8 +43,8 @@ class RimEclipseCaseCollection : public caf::PdmObject
CAF_PDM_HEADER_INIT;
public:
RimEclipseCaseCollection( void );
~RimEclipseCaseCollection( void ) override;
RimEclipseCaseCollection();
~RimEclipseCaseCollection() override;
caf::PdmChildArrayField<RimEclipseCase*> cases;
caf::PdmChildArrayField<RimIdenticalGridCaseGroup*> caseGroups;

View File

@ -60,7 +60,7 @@ public:
double sampleSpacing() const override;
protected:
typedef RimContourMapProjection::CellIndexAndResult CellIndexAndResult;
using CellIndexAndResult = RimContourMapProjection::CellIndexAndResult;
void updateGridInformation() override;
std::vector<double> retrieveParameterWeights() override;

View File

@ -321,7 +321,7 @@ void RimEclipseContourMapView::appendContourMapProjectionToModel()
if ( frameScene )
{
cvf::String name = "ContourMapProjection";
this->removeModelByName( frameScene, name );
RimEclipseContourMapView::removeModelByName( frameScene, name );
cvf::ref<cvf::ModelBasicList> contourMapProjectionModelBasicList = new cvf::ModelBasicList;
contourMapProjectionModelBasicList->setName( name );
@ -346,7 +346,7 @@ void RimEclipseContourMapView::appendContourLinesToModel()
if ( frameScene )
{
cvf::String name = "ContourMapLines";
this->removeModelByName( frameScene, name );
RimEclipseContourMapView::removeModelByName( frameScene, name );
cvf::ref<cvf::ModelBasicList> contourMapLabelModelBasicList = new cvf::ModelBasicList;
contourMapLabelModelBasicList->setName( name );
@ -371,7 +371,7 @@ void RimEclipseContourMapView::appendPickPointVisToModel()
if ( frameScene )
{
cvf::String name = "ContourMapPickPoint";
this->removeModelByName( frameScene, name );
RimEclipseContourMapView::removeModelByName( frameScene, name );
cvf::ref<cvf::ModelBasicList> contourMapProjectionModelBasicList = new cvf::ModelBasicList;
contourMapProjectionModelBasicList->setName( name );

View File

@ -46,7 +46,7 @@ public:
RESOLVED_NOT_SAVED,
RESOLVED
};
typedef caf::AppEnum<ResolveState> ResolveStateEnum;
using ResolveStateEnum = caf::AppEnum<ResolveState>;
// Fields:
caf::PdmField<QString> resultName;

View File

@ -61,7 +61,7 @@ public:
FLOW_TR_INJECTORS,
FLOW_TR_BY_SELECTION
};
typedef caf::AppEnum<RimEclipseResultDefinition::FlowTracerSelectionType> FlowTracerSelectionEnum;
using FlowTracerSelectionEnum = caf::AppEnum<RimEclipseResultDefinition::FlowTracerSelectionType>;
enum FlowTracerSelectionState
{

View File

@ -834,7 +834,7 @@ void RimEclipseView::updateVisibleGeometries()
cvf::Scene* frameScene = nativeOrOverrideViewer()->frame( m_currentTimeStep, isUsingOverrideViewer() );
if ( frameScene )
{
this->removeModelByName( frameScene, frameParts->name() );
RimEclipseView::removeModelByName( frameScene, frameParts->name() );
frameScene->addModel( frameParts.p() );
frameParts->updateBoundingBoxesRecursive();
}
@ -921,7 +921,7 @@ void RimEclipseView::appendWellsAndFracturesToModel()
// Simulation Wells
{
cvf::String name = "SimWellPipeMod";
this->removeModelByName( frameScene, name );
RimEclipseView::removeModelByName( frameScene, name );
cvf::ref<cvf::ModelBasicList> simWellModelBasicList = new cvf::ModelBasicList;
simWellModelBasicList->setName( name );
@ -938,7 +938,7 @@ void RimEclipseView::appendWellsAndFracturesToModel()
// Well Paths
{
cvf::String name = "WellPathMod";
this->removeModelByName( frameScene, name );
RimEclipseView::removeModelByName( frameScene, name );
cvf::ref<cvf::ModelBasicList> wellPathModelBasicList = new cvf::ModelBasicList;
wellPathModelBasicList->setName( name );
@ -951,7 +951,7 @@ void RimEclipseView::appendWellsAndFracturesToModel()
// Sim Well Fractures
{
cvf::String name = "SimWellFracturesModel";
this->removeModelByName( frameScene, name );
RimEclipseView::removeModelByName( frameScene, name );
cvf::ref<cvf::ModelBasicList> simWellFracturesModelBasicList = new cvf::ModelBasicList;
simWellFracturesModelBasicList->setName( name );
@ -996,7 +996,7 @@ void RimEclipseView::appendElementVectorResultToModel()
{
// Element Vector Results
cvf::String name = "ElementVectorModelMod";
this->removeModelByName( frameScene, name );
RimEclipseView::removeModelByName( frameScene, name );
cvf::ref<cvf::ModelBasicList> frameParts = new cvf::ModelBasicList;
frameParts->setName( name );
@ -1026,7 +1026,7 @@ void RimEclipseView::appendStreamlinesToModel()
if ( frameScene )
{
cvf::String name = "StreamlinesModel";
this->removeModelByName( frameScene, name );
RimEclipseView::removeModelByName( frameScene, name );
cvf::ref<cvf::ModelBasicList> frameParts = new cvf::ModelBasicList;
frameParts->setName( name );

View File

@ -45,7 +45,7 @@ public:
PL_EQUIL_WATER_OIL_CONTACT,
PL_EQUIL_GAS_OIL_CONTACT
};
typedef caf::AppEnum<PlotAxisAnnotationType> ExportKeywordEnum;
using ExportKeywordEnum = caf::AppEnum<PlotAxisAnnotationType>;
RimEquilibriumAxisAnnotation();

View File

@ -46,7 +46,7 @@ public:
USER_DEFINED
};
typedef caf::AppEnum<RangeModeType> RangeModeEnum;
using RangeModeEnum = caf::AppEnum<RangeModeType>;
virtual const caf::TitledOverlayFrame* titledOverlayFrame() const = 0;
virtual caf::TitledOverlayFrame* titledOverlayFrame() = 0;

View File

@ -98,7 +98,7 @@ void caf::AppEnum<RimMudWeightWindowParameters::NonReservoirPorePressureType>::s
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimMudWeightWindowParameters::RimMudWeightWindowParameters( void )
RimMudWeightWindowParameters::RimMudWeightWindowParameters()
{
CAF_PDM_InitScriptableObjectWithNameAndComment( "Mud Weight Window Parameters",
"",

View File

@ -76,7 +76,7 @@ public:
PER_ELEMENT
};
RimMudWeightWindowParameters( void );
RimMudWeightWindowParameters();
SourceType wellDeviationType() const;
double wellDeviation() const;
@ -149,8 +149,8 @@ private:
caf::PdmField<double> m_obg0Fixed;
caf::PdmField<QString> m_obg0Address;
typedef std::tuple<caf::PdmField<caf::AppEnum<SourceType>>*, caf::PdmField<double>*, caf::PdmField<QString>*> ParameterPdmFields;
std::map<ParameterType, ParameterPdmFields> m_parameterFields;
using ParameterPdmFields = std::tuple<caf::PdmField<caf::AppEnum<SourceType>>*, caf::PdmField<double>*, caf::PdmField<QString>*>;
std::map<ParameterType, ParameterPdmFields> m_parameterFields;
caf::PdmField<double> m_airGap;
caf::PdmField<double> m_shMultiplier;

View File

@ -26,7 +26,7 @@ CAF_PDM_XML_ABSTRACT_SOURCE_INIT( RimNamedObject, "NamedObject" ); // Do not use
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimNamedObject::RimNamedObject( void )
RimNamedObject::RimNamedObject()
{
CAF_PDM_InitScriptableObject( "Named object" );
CAF_PDM_InitScriptableField( &m_name, "Name", QString(), "Name" );
@ -35,7 +35,7 @@ RimNamedObject::RimNamedObject( void )
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimNamedObject::~RimNamedObject( void )
RimNamedObject::~RimNamedObject()
{
}

View File

@ -30,8 +30,8 @@ class RimNamedObject : public caf::PdmObject
CAF_PDM_HEADER_INIT;
public:
RimNamedObject( void );
~RimNamedObject( void ) override;
RimNamedObject();
~RimNamedObject() override;
virtual QString name() const;
void setName( const QString& name );

View File

@ -38,7 +38,7 @@ CAF_PDM_SOURCE_INIT( RimOilField, "ResInsightOilField" );
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimOilField::RimOilField( void )
RimOilField::RimOilField()
{
CAF_PDM_InitObject( "Oil Field" );
@ -84,7 +84,7 @@ RimOilField::RimOilField( void )
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimOilField::~RimOilField( void )
RimOilField::~RimOilField()
{
}

View File

@ -50,8 +50,8 @@ class RimOilField : public caf::PdmObject
CAF_PDM_HEADER_INIT;
public:
RimOilField( void );
~RimOilField( void ) override;
RimOilField();
~RimOilField() override;
RimFractureTemplateCollection* fractureDefinitionCollection();
const RimFractureTemplateCollection* fractureDefinitionCollection() const;

View File

@ -40,11 +40,11 @@ public:
caf::Signal<> fillColorChanged;
public:
typedef caf::AppEnum<RiuQwtPlotCurveDefines::CurveInterpolationEnum> CurveInterpolation;
typedef caf::AppEnum<RiuQwtPlotCurveDefines::LineStyleEnum> LineStyle;
typedef caf::AppEnum<RiuPlotCurveSymbol::PointSymbolEnum> PointSymbol;
typedef caf::AppEnum<RiuPlotCurveSymbol::LabelPosition> LabelPosition;
typedef caf::AppEnum<Qt::BrushStyle> FillStyle;
using CurveInterpolation = caf::AppEnum<RiuQwtPlotCurveDefines::CurveInterpolationEnum>;
using LineStyle = caf::AppEnum<RiuQwtPlotCurveDefines::LineStyleEnum>;
using PointSymbol = caf::AppEnum<RiuPlotCurveSymbol::PointSymbolEnum>;
using LabelPosition = caf::AppEnum<RiuPlotCurveSymbol::LabelPosition>;
using FillStyle = caf::AppEnum<Qt::BrushStyle>;
public:
RimPlotCurveAppearance();

View File

@ -127,7 +127,7 @@ CAF_PDM_SOURCE_INIT( RimProject, "ResInsightProject" );
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimProject::RimProject( void )
RimProject::RimProject()
: m_nextValidCaseId( 0 )
, m_nextValidCaseGroupId( 0 )
, m_nextValidViewId( -1 )
@ -240,7 +240,7 @@ RimProject::RimProject( void )
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimProject::~RimProject( void )
RimProject::~RimProject()
{
}

View File

@ -90,8 +90,8 @@ class RimProject : public caf::PdmDocument
CAF_PDM_HEADER_INIT;
public:
RimProject( void );
~RimProject( void ) override;
RimProject();
~RimProject() override;
static RimProject* current();
caf::PdmChildArrayField<RimOilField*> oilFields;

View File

@ -102,7 +102,7 @@ public:
UNDEFINED
};
typedef caf::AppEnum<ColorRangesType> ColorRangeEnum;
using ColorRangeEnum = caf::AppEnum<ColorRangesType>;
enum class MappingType
{
@ -112,14 +112,14 @@ public:
LOG10_DISCRETE,
CATEGORY_INTEGER
};
typedef caf::AppEnum<MappingType> MappingEnum;
using MappingEnum = caf::AppEnum<MappingType>;
enum class CategoryColorModeType
{
INTERPOLATE,
EXCLUSIVELY_COLORS
};
typedef caf::AppEnum<CategoryColorModeType> CategoryColorModeEnum;
using CategoryColorModeEnum = caf::AppEnum<CategoryColorModeType>;
void onRecreateLegend() override;

View File

@ -55,7 +55,7 @@ public:
PIPES_OPEN_IN_VISIBLE_CELLS,
PIPES_FORCE_ALL_ON
};
typedef caf::AppEnum<RimSimWellInViewCollection::WellVisibilityType> WellVisibilityEnum;
using WellVisibilityEnum = caf::AppEnum<RimSimWellInViewCollection::WellVisibilityType>;
enum WellCellsRangeFilterType
{
@ -63,7 +63,7 @@ public:
RANGE_ADD_INDIVIDUAL,
RANGE_ADD_NONE
};
typedef caf::AppEnum<RimSimWellInViewCollection::WellCellsRangeFilterType> WellCellsRangeFilterEnum;
using WellCellsRangeFilterEnum = caf::AppEnum<RimSimWellInViewCollection::WellCellsRangeFilterType>;
enum WellFenceType
{
@ -71,14 +71,14 @@ public:
J_DIRECTION,
I_DIRECTION
};
typedef caf::AppEnum<RimSimWellInViewCollection::WellFenceType> WellFenceEnum;
using WellFenceEnum = caf::AppEnum<RimSimWellInViewCollection::WellFenceType>;
enum WellHeadPositionType
{
WELLHEAD_POS_ACTIVE_CELLS_BB,
WELLHEAD_POS_TOP_COLUMN
};
typedef caf::AppEnum<RimSimWellInViewCollection::WellHeadPositionType> WellHeadPositionEnum;
using WellHeadPositionEnum = caf::AppEnum<RimSimWellInViewCollection::WellHeadPositionType>;
enum WellPipeCoordType
{
@ -86,7 +86,7 @@ public:
WELLPIPE_INTERPOLATED
};
typedef caf::AppEnum<RimSimWellInViewCollection::WellPipeCoordType> WellPipeCoordEnum;
using WellPipeCoordEnum = caf::AppEnum<RimSimWellInViewCollection::WellPipeCoordType>;
enum WellPipeColors
{
@ -110,7 +110,7 @@ public:
CUMULATIVE_PRODUCTION_INJECTION_RATES
};
typedef caf::AppEnum<RimSimWellInViewCollection::WellPipeColors> WellPipeColorsEnum;
using WellPipeColorsEnum = caf::AppEnum<RimSimWellInViewCollection::WellPipeColors>;
caf::PdmField<bool> isActive;
caf::PdmField<bool> showWellsIntersectingVisibleCells;

View File

@ -73,7 +73,7 @@ RimUserDefinedCalculation* RimUserDefinedCalculationCollection::addCalculationCo
}
QString expression = calcCopy->expression();
QString currVarName = calcCopy->findLeftHandSide( expression );
QString currVarName = RimUserDefinedCalculation::findLeftHandSide( expression );
QString newVarName = currVarName;
while ( calcNames.count( newVarName ) > 0 )

View File

@ -29,7 +29,7 @@ CAF_PDM_SOURCE_INIT( RimViewLinkerCollection, "RimViewLinkerCollection" );
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimViewLinkerCollection::RimViewLinkerCollection( void )
RimViewLinkerCollection::RimViewLinkerCollection()
{
CAF_PDM_InitObject( "Linked Views", ":/LinkView.svg" );
@ -43,7 +43,7 @@ RimViewLinkerCollection::RimViewLinkerCollection( void )
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimViewLinkerCollection::~RimViewLinkerCollection( void )
RimViewLinkerCollection::~RimViewLinkerCollection()
{
if ( viewLinker() ) delete viewLinker();
}

View File

@ -34,8 +34,8 @@ class RimViewLinkerCollection : public caf::PdmObject
CAF_PDM_HEADER_INIT;
public:
RimViewLinkerCollection( void );
~RimViewLinkerCollection( void ) override;
RimViewLinkerCollection();
~RimViewLinkerCollection() override;
caf::PdmField<bool> isActive;
caf::PdmChildField<RimViewLinker*> viewLinker;

View File

@ -40,7 +40,7 @@ CAF_PDM_XML_ABSTRACT_SOURCE_INIT( RimViewWindow, "ViewWindow" ); // Do not use.
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimViewWindow::RimViewWindow( void )
RimViewWindow::RimViewWindow()
{
CAF_PDM_InitScriptableObjectWithNameAndComment( "View window", "", "", "", "ViewWindow", "The Base Class for all Views and Plots in ResInsight" );
@ -59,7 +59,7 @@ RimViewWindow::RimViewWindow( void )
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimViewWindow::~RimViewWindow( void )
RimViewWindow::~RimViewWindow()
{
if ( m_windowController() ) delete m_windowController();
}

View File

@ -56,8 +56,8 @@ class RimViewWindow : public caf::PdmObject, public caf::FontHolderInterface
CAF_PDM_HEADER_INIT;
public:
RimViewWindow( void );
~RimViewWindow( void ) override;
RimViewWindow();
~RimViewWindow() override;
virtual int id() const = 0;

View File

@ -31,7 +31,7 @@
class RimElasticPropertyScalingCollection;
typedef std::tuple<QString, QString, QString> FaciesKey;
using FaciesKey = std::tuple<QString, QString, QString>;
//==================================================================================================
///

View File

@ -84,8 +84,8 @@ public:
GRADIENT
};
RimStimPlanModel( void );
~RimStimPlanModel( void ) override;
RimStimPlanModel();
~RimStimPlanModel() override;
void setMD( double md );

View File

@ -123,7 +123,7 @@ private:
RimStimPlanModel* m_stimPlanModel;
std::vector<std::unique_ptr<RimStimPlanModelPropertyCalculator>> m_resultCalculators;
typedef std::pair<RiaDefines::CurveProperty, int> ResultKey;
typedef std::tuple<std::vector<double>, std::vector<double>, std::vector<double>, double> ResultData;
mutable std::map<ResultKey, ResultData> m_resultCache;
using ResultKey = std::pair<RiaDefines::CurveProperty, int>;
using ResultData = std::tuple<std::vector<double>, std::vector<double>, std::vector<double>, double>;
mutable std::map<ResultKey, ResultData> m_resultCache;
};

View File

@ -30,7 +30,7 @@ CAF_PDM_SOURCE_INIT( RimStimPlanModelCollection, "StimPlanModelCollection" );
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimStimPlanModelCollection::RimStimPlanModelCollection( void )
RimStimPlanModelCollection::RimStimPlanModelCollection()
{
CAF_PDM_InitScriptableObject( "StimPlan Models" );

View File

@ -35,8 +35,8 @@ class RimStimPlanModelCollection : public RimCheckableNamedObject
CAF_PDM_HEADER_INIT;
public:
RimStimPlanModelCollection( void );
~RimStimPlanModelCollection( void ) override;
RimStimPlanModelCollection();
~RimStimPlanModelCollection() override;
bool hasStimPlanModels() const;
void addStimPlanModel( RimStimPlanModel* fracture );

View File

@ -84,9 +84,9 @@ protected:
const std::vector<double>& faciesValues,
std::vector<double>& values ) const;
typedef std::pair<double, double> DepthValuePair;
typedef std::vector<DepthValuePair> DepthValuePairVector;
typedef std::map<int, DepthValuePairVector> EqlNumToDepthValuePairMap;
using DepthValuePair = std::pair<double, double>;
using DepthValuePairVector = std::vector<DepthValuePair>;
using EqlNumToDepthValuePairMap = std::map<int, DepthValuePairVector>;
static void sortAndRemoveDuplicates( DepthValuePairVector& depthValuePairs );
static bool buildPressureTablesPerEqlNum( const RimStimPlanModel* stimPlanModel,

View File

@ -49,8 +49,8 @@ class RimStimPlanModelTemplate : public RimNamedObject
CAF_PDM_HEADER_INIT;
public:
RimStimPlanModelTemplate( void );
~RimStimPlanModelTemplate( void ) override;
RimStimPlanModelTemplate();
~RimStimPlanModelTemplate() override;
caf::Signal<> changed;

View File

@ -1442,7 +1442,7 @@ std::pair<double, double> RimSummaryMultiPlot::adjustedMinMax( const RimPlotAxis
{
if ( !axis->isLogarithmicScaleEnabled() )
{
int maxMajorTickIntervalCount = axis->tickmarkCountFromEnum( axis->majorTickmarkCount() );
int maxMajorTickIntervalCount = RimPlotAxisProperties::tickmarkCountFromEnum( axis->majorTickmarkCount() );
double stepSize = 0.0;
QwtLinearScaleEngine scaleEngine;

Some files were not shown because too many files have changed in this diff Show More