mirror of
https://github.com/OPM/ResInsight.git
synced 2025-01-05 21:53:27 -06:00
#6232 Make fracture model pdm objects scriptable.
This commit is contained in:
parent
67af692f96
commit
7c69fc61ef
@ -51,6 +51,8 @@
|
||||
#include "RimWellPathGeometryDef.h"
|
||||
#include "RimWellPathTarget.h"
|
||||
|
||||
#include "cafPdmFieldIOScriptability.h"
|
||||
#include "cafPdmObjectScriptability.h"
|
||||
#include "cafPdmUiDoubleSliderEditor.h"
|
||||
#include "cafPdmUiPushButtonEditor.h"
|
||||
#include "cafPdmUiToolButtonEditor.h"
|
||||
@ -83,65 +85,89 @@ void caf::AppEnum<RimFractureModel::ExtractionType>::setUp()
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RimFractureModel::RimFractureModel()
|
||||
{
|
||||
CAF_PDM_InitObject( "FractureModel", "", "", "" );
|
||||
CAF_PDM_InitScriptableObject( "FractureModel", "", "", "" );
|
||||
|
||||
CAF_PDM_InitField( &m_MD, "MD", 0.0, "MD", "", "", "" );
|
||||
CAF_PDM_InitScriptableField( &m_MD, "MD", 0.0, "MD", "", "", "" );
|
||||
|
||||
CAF_PDM_InitField( &m_extractionType,
|
||||
"ExtractionType",
|
||||
caf::AppEnum<ExtractionType>( ExtractionType::TRUE_STRATIGRAPHIC_THICKNESS ),
|
||||
"Extraction Type",
|
||||
"",
|
||||
"",
|
||||
"" );
|
||||
CAF_PDM_InitScriptableField( &m_extractionType,
|
||||
"ExtractionType",
|
||||
caf::AppEnum<ExtractionType>( ExtractionType::TRUE_STRATIGRAPHIC_THICKNESS ),
|
||||
"Extraction Type",
|
||||
"",
|
||||
"",
|
||||
"" );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_anchorPosition, "AnchorPosition", "Anchor Position", "", "", "" );
|
||||
CAF_PDM_InitScriptableFieldNoDefault( &m_anchorPosition, "AnchorPosition", "Anchor Position", "", "", "" );
|
||||
m_anchorPosition.uiCapability()->setUiReadOnly( true );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_thicknessDirection, "ThicknessDirection", "Thickness Direction", "", "", "" );
|
||||
CAF_PDM_InitScriptableFieldNoDefault( &m_thicknessDirection, "ThicknessDirection", "Thickness Direction", "", "", "" );
|
||||
m_thicknessDirection.uiCapability()->setUiReadOnly( true );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_thicknessDirectionWellPath,
|
||||
"ThicknessDirectionWellPath",
|
||||
"Thickness Direction Well Path",
|
||||
"",
|
||||
"",
|
||||
"" );
|
||||
CAF_PDM_InitScriptableFieldNoDefault( &m_thicknessDirectionWellPath,
|
||||
"ThicknessDirectionWellPath",
|
||||
"Thickness Direction Well Path",
|
||||
"",
|
||||
"",
|
||||
"" );
|
||||
|
||||
CAF_PDM_InitField( &m_boundingBoxHorizontal, "BoundingBoxHorizontal", 50.0, "Bounding Box Horizontal", "", "", "" );
|
||||
CAF_PDM_InitField( &m_boundingBoxVertical, "BoundingBoxVertical", 100.0, "Bounding Box Vertical", "", "", "" );
|
||||
CAF_PDM_InitScriptableField( &m_boundingBoxHorizontal, "BoundingBoxHorizontal", 50.0, "Bounding Box Horizontal", "", "", "" );
|
||||
CAF_PDM_InitScriptableField( &m_boundingBoxVertical, "BoundingBoxVertical", 100.0, "Bounding Box Vertical", "", "", "" );
|
||||
|
||||
CAF_PDM_InitField( &m_defaultPorosity, "DefaultPorosity", 0.0, "Default Porosity", "", "", "" );
|
||||
CAF_PDM_InitField( &m_defaultPermeability, "DefaultPermeability", 10.0e-6, "Default Permeability", "", "", "" );
|
||||
CAF_PDM_InitScriptableField( &m_defaultPorosity, "DefaultPorosity", 0.0, "Default Porosity", "", "", "" );
|
||||
CAF_PDM_InitScriptableField( &m_defaultPermeability, "DefaultPermeability", 10.0e-6, "Default Permeability", "", "", "" );
|
||||
|
||||
// Stress unit: bar
|
||||
// Stress gradient unit: bar/m
|
||||
// Depth is meter
|
||||
CAF_PDM_InitField( &m_verticalStress, "VerticalStress", 879.0, "Vertical Stress", "", "", "" );
|
||||
CAF_PDM_InitField( &m_verticalStressGradient, "VerticalStressGradient", 0.238, "Vertical Stress Gradient", "", "", "" );
|
||||
CAF_PDM_InitField( &m_stressDepth, "StressDepth", 1000.0, "Stress Depth", "", "", "" );
|
||||
CAF_PDM_InitScriptableField( &m_verticalStress, "VerticalStress", 879.0, "Vertical Stress", "", "", "" );
|
||||
CAF_PDM_InitScriptableField( &m_verticalStressGradient,
|
||||
"VerticalStressGradient",
|
||||
0.238,
|
||||
"Vertical Stress Gradient",
|
||||
"",
|
||||
"",
|
||||
"" );
|
||||
CAF_PDM_InitScriptableField( &m_stressDepth, "StressDepth", 1000.0, "Stress Depth", "", "", "" );
|
||||
|
||||
CAF_PDM_InitField( &m_overburdenHeight, "OverburdenHeight", 50.0, "Overburden Height", "", "", "" );
|
||||
CAF_PDM_InitFieldNoDefault( &m_overburdenFormation, "OverburdenFormation", "Overburden Formation", "", "", "" );
|
||||
CAF_PDM_InitFieldNoDefault( &m_overburdenFacies, "OverburdenFacies", "Overburden Facies", "", "", "" );
|
||||
CAF_PDM_InitField( &m_overburdenPorosity, "OverburdenPorosity", 0.0, "Overburden Porosity", "", "", "" );
|
||||
CAF_PDM_InitField( &m_overburdenPermeability, "OverburdenPermeability", 10.0e-6, "Overburden Permeability", "", "", "" );
|
||||
CAF_PDM_InitField( &m_overburdenFluidDensity, "OverburdenFluidDensity", 1.03, "Overburden Fluid Density [g/cm^3]", "", "", "" );
|
||||
CAF_PDM_InitScriptableField( &m_overburdenHeight, "OverburdenHeight", 50.0, "Overburden Height", "", "", "" );
|
||||
CAF_PDM_InitScriptableFieldNoDefault( &m_overburdenFormation, "OverburdenFormation", "Overburden Formation", "", "", "" );
|
||||
CAF_PDM_InitScriptableFieldNoDefault( &m_overburdenFacies, "OverburdenFacies", "Overburden Facies", "", "", "" );
|
||||
CAF_PDM_InitScriptableField( &m_overburdenPorosity, "OverburdenPorosity", 0.0, "Overburden Porosity", "", "", "" );
|
||||
CAF_PDM_InitScriptableField( &m_overburdenPermeability,
|
||||
"OverburdenPermeability",
|
||||
10.0e-6,
|
||||
"Overburden Permeability",
|
||||
"",
|
||||
"",
|
||||
"" );
|
||||
CAF_PDM_InitScriptableField( &m_overburdenFluidDensity,
|
||||
"OverburdenFluidDensity",
|
||||
1.03,
|
||||
"Overburden Fluid Density [g/cm^3]",
|
||||
"",
|
||||
"",
|
||||
"" );
|
||||
|
||||
CAF_PDM_InitField( &m_underburdenHeight, "UnderburdenHeight", 50.0, "Underburden Height", "", "", "" );
|
||||
CAF_PDM_InitFieldNoDefault( &m_underburdenFormation, "UnderburdenFormation", "Underburden Formation", "", "", "" );
|
||||
CAF_PDM_InitFieldNoDefault( &m_underburdenFacies, "UnderburdenFacies", "Underburden Facies", "", "", "" );
|
||||
CAF_PDM_InitField( &m_underburdenPorosity, "UnderburdenPorosity", 0.0, "Underburden Porosity", "", "", "" );
|
||||
CAF_PDM_InitField( &m_underburdenPermeability, "UnderburdenPermeability", 10.0e-6, "Underburden Permeability", "", "", "" );
|
||||
CAF_PDM_InitField( &m_underburdenFluidDensity,
|
||||
"UnderburdenFluidDensity",
|
||||
1.03,
|
||||
"Underburden Fluid Density [g/cm^3]",
|
||||
"",
|
||||
"",
|
||||
"" );
|
||||
CAF_PDM_InitScriptableField( &m_underburdenHeight, "UnderburdenHeight", 50.0, "Underburden Height", "", "", "" );
|
||||
CAF_PDM_InitScriptableFieldNoDefault( &m_underburdenFormation, "UnderburdenFormation", "Underburden Formation", "", "", "" );
|
||||
CAF_PDM_InitScriptableFieldNoDefault( &m_underburdenFacies, "UnderburdenFacies", "Underburden Facies", "", "", "" );
|
||||
CAF_PDM_InitScriptableField( &m_underburdenPorosity, "UnderburdenPorosity", 0.0, "Underburden Porosity", "", "", "" );
|
||||
CAF_PDM_InitScriptableField( &m_underburdenPermeability,
|
||||
"UnderburdenPermeability",
|
||||
10.0e-6,
|
||||
"Underburden Permeability",
|
||||
"",
|
||||
"",
|
||||
"" );
|
||||
CAF_PDM_InitScriptableField( &m_underburdenFluidDensity,
|
||||
"UnderburdenFluidDensity",
|
||||
1.03,
|
||||
"Underburden Fluid Density [g/cm^3]",
|
||||
"",
|
||||
"",
|
||||
"" );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_elasticProperties, "ElasticProperties", "Elastic Properties", "", "", "" );
|
||||
CAF_PDM_InitScriptableFieldNoDefault( &m_elasticProperties, "ElasticProperties", "Elastic Properties", "", "", "" );
|
||||
m_elasticProperties.uiCapability()->setUiHidden( true );
|
||||
m_elasticProperties.uiCapability()->setUiTreeHidden( true );
|
||||
}
|
||||
|
@ -21,7 +21,9 @@
|
||||
#include "RimFractureModel.h"
|
||||
#include "RimProject.h"
|
||||
|
||||
#include "cafPdmFieldIOScriptability.h"
|
||||
#include "cafPdmObject.h"
|
||||
#include "cafPdmObjectScriptability.h"
|
||||
|
||||
CAF_PDM_SOURCE_INIT( RimFractureModelCollection, "FractureModelCollection" );
|
||||
|
||||
@ -30,9 +32,9 @@ CAF_PDM_SOURCE_INIT( RimFractureModelCollection, "FractureModelCollection" );
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RimFractureModelCollection::RimFractureModelCollection( void )
|
||||
{
|
||||
CAF_PDM_InitObject( "Fracture Models", "", "", "" );
|
||||
CAF_PDM_InitScriptableObject( "Fracture Models", "", "", "" );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_fractureModels, "FractureModels", "", "", "", "" );
|
||||
CAF_PDM_InitScriptableFieldNoDefault( &m_fractureModels, "FractureModels", "", "", "", "" );
|
||||
m_fractureModels.uiCapability()->setUiHidden( true );
|
||||
|
||||
setName( "Fracture Models" );
|
||||
|
@ -22,6 +22,8 @@
|
||||
|
||||
#include "RicElasticPropertiesImportTools.h"
|
||||
|
||||
#include "cafPdmFieldIOScriptability.h"
|
||||
#include "cafPdmObjectScriptability.h"
|
||||
#include "cafPdmUiLineEditor.h"
|
||||
#include "cafPdmUiTextEditor.h"
|
||||
|
||||
@ -32,13 +34,13 @@ CAF_PDM_SOURCE_INIT( RimElasticProperties, "ElasticProperties" );
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RimElasticProperties::RimElasticProperties()
|
||||
{
|
||||
CAF_PDM_InitObject( "RimElasticProperties", "", "", "" );
|
||||
CAF_PDM_InitScriptableObject( "RimElasticProperties", "", "", "" );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_filePath, "FilePath", "File Path", "", "", "" );
|
||||
CAF_PDM_InitScriptableFieldNoDefault( &m_filePath, "FilePath", "File Path", "", "", "" );
|
||||
m_filePath.uiCapability()->setUiReadOnly( true );
|
||||
m_filePath.uiCapability()->setUiEditorTypeName( caf::PdmUiLineEditor::uiEditorTypeName() );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_propertiesTable, "PropertiesTable", "Properties Table", "", "", "" );
|
||||
CAF_PDM_InitScriptableFieldNoDefault( &m_propertiesTable, "PropertiesTable", "Properties Table", "", "", "" );
|
||||
m_propertiesTable.uiCapability()->setUiEditorTypeName( caf::PdmUiTextEditor::uiEditorTypeName() );
|
||||
m_propertiesTable.uiCapability()->setUiLabelPosition( caf::PdmUiItemInfo::HIDDEN );
|
||||
m_propertiesTable.uiCapability()->setUiReadOnly( true );
|
||||
|
@ -44,7 +44,7 @@ RimFractureModelPlot::RimFractureModelPlot()
|
||||
{
|
||||
CAF_PDM_InitScriptableObject( "Fracture Model Plot", "", "", "A fracture model plot" );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_fractureModel, "FractureModel", "Fracture Model", "", "", "" );
|
||||
CAF_PDM_InitScriptableFieldNoDefault( &m_fractureModel, "FractureModel", "Fracture Model", "", "", "" );
|
||||
m_fractureModel.uiCapability()->setUiTreeChildrenHidden( true );
|
||||
m_fractureModel.uiCapability()->setUiHidden( true );
|
||||
|
||||
|
@ -20,6 +20,9 @@
|
||||
|
||||
#include "RimFractureModelPlot.h"
|
||||
|
||||
#include "cafPdmFieldIOScriptability.h"
|
||||
#include "cafPdmObjectScriptability.h"
|
||||
|
||||
CAF_PDM_SOURCE_INIT( RimFractureModelPlotCollection, "FractureModelPlotCollection" );
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@ -27,9 +30,9 @@ CAF_PDM_SOURCE_INIT( RimFractureModelPlotCollection, "FractureModelPlotCollectio
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RimFractureModelPlotCollection::RimFractureModelPlotCollection()
|
||||
{
|
||||
CAF_PDM_InitObject( "FractureModelPlots", ":/WellLogPlots16x16.png", "", "" );
|
||||
CAF_PDM_InitScriptableObject( "FractureModelPlots", ":/WellLogPlots16x16.png", "", "" );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_fractureModelPlots, "FractureModelPlots", "", "", "", "" );
|
||||
CAF_PDM_InitScriptableFieldNoDefault( &m_fractureModelPlots, "FractureModelPlots", "", "", "", "" );
|
||||
m_fractureModelPlots.uiCapability()->setUiHidden( true );
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user