2017-05-11 06:33:18 -05:00
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
//
|
|
|
|
// Copyright (C) 2011- Statoil ASA
|
|
|
|
// Copyright (C) 2013- Ceetron Solutions AS
|
2019-09-06 03:40:57 -05:00
|
|
|
//
|
2017-05-11 06:33:18 -05:00
|
|
|
// 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.
|
2019-09-06 03:40:57 -05:00
|
|
|
//
|
2017-05-11 06:33:18 -05:00
|
|
|
// 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.
|
2019-09-06 03:40:57 -05:00
|
|
|
//
|
|
|
|
// See the GNU General Public License at <http://www.gnu.org/licenses/gpl.html>
|
2017-05-11 06:33:18 -05:00
|
|
|
// for more details.
|
|
|
|
//
|
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
2017-05-21 02:15:54 -05:00
|
|
|
#include "Rim3dPropertiesInterface.h"
|
2019-09-06 03:40:57 -05:00
|
|
|
#include "RimCheckableNamedObject.h"
|
2018-10-09 06:42:03 -05:00
|
|
|
#include "RimWellPathComponentInterface.h"
|
2017-05-11 06:33:18 -05:00
|
|
|
|
2021-01-21 05:58:46 -06:00
|
|
|
#include "RiaDefines.h"
|
2017-06-20 03:40:39 -05:00
|
|
|
|
2018-10-10 04:10:56 -05:00
|
|
|
#include "cafPdmChildArrayField.h"
|
2019-09-06 03:40:57 -05:00
|
|
|
#include "cafPdmField.h"
|
2017-05-11 06:33:18 -05:00
|
|
|
#include "cafPdmObject.h"
|
|
|
|
|
2017-05-30 04:56:18 -05:00
|
|
|
#include <QDate>
|
|
|
|
|
2018-10-10 04:10:56 -05:00
|
|
|
class RimWellPathValve;
|
|
|
|
|
2017-05-11 06:33:18 -05:00
|
|
|
//==================================================================================================
|
2019-09-06 03:40:57 -05:00
|
|
|
///
|
2017-05-11 06:33:18 -05:00
|
|
|
//==================================================================================================
|
2023-02-26 03:48:40 -06:00
|
|
|
class RimPerforationInterval : public RimCheckableNamedObject, public Rim3dPropertiesInterface, public RimWellPathComponentInterface
|
2017-05-11 06:33:18 -05:00
|
|
|
{
|
|
|
|
CAF_PDM_HEADER_INIT;
|
2018-10-26 05:09:29 -05:00
|
|
|
|
2017-05-11 06:33:18 -05:00
|
|
|
public:
|
|
|
|
RimPerforationInterval();
|
2018-10-18 12:45:57 -05:00
|
|
|
~RimPerforationInterval() override;
|
2017-05-11 06:33:18 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void setStartAndEndMD( double startMD, double endMD );
|
2018-06-22 02:04:26 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void enableCustomStartDate( bool enable );
|
|
|
|
void setCustomStartDate( const QDate& date );
|
2018-06-22 02:04:26 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void setCustomEndDate( const QDate& date );
|
2018-06-22 02:04:26 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void setDiameter( double diameter );
|
|
|
|
void setSkinFactor( double skinFactor );
|
2021-01-21 05:58:46 -06:00
|
|
|
double diameter( RiaDefines::EclipseUnitSystem unitSystem ) const;
|
2019-09-06 03:40:57 -05:00
|
|
|
double skinFactor() const;
|
2017-05-12 03:01:37 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
bool isActiveOnDate( const QDateTime& date ) const;
|
2017-05-30 08:42:05 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
cvf::BoundingBox boundingBoxInDomainCoords() const override;
|
2017-05-21 02:15:54 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void setUnitSystemSpecificDefaults();
|
2017-06-20 05:36:12 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
void addValve( RimWellPathValve* valve );
|
|
|
|
std::vector<RimWellPathValve*> valves() const;
|
|
|
|
void updateAllReferringTracks();
|
2018-10-10 04:10:56 -05:00
|
|
|
|
2018-10-09 04:06:10 -05:00
|
|
|
// RimWellPathCompletionInterface overrides
|
2019-09-06 03:40:57 -05:00
|
|
|
bool isEnabled() const override;
|
|
|
|
RiaDefines::WellPathComponentType componentType() const override;
|
|
|
|
QString componentLabel() const override;
|
|
|
|
QString componentTypeLabel() const override;
|
|
|
|
cvf::Color3f defaultComponentColor() const override;
|
|
|
|
double startMD() const override;
|
|
|
|
double endMD() const override;
|
2021-06-28 06:10:57 -05:00
|
|
|
void applyOffset( double offsetMD ) override;
|
2018-10-09 04:06:10 -05:00
|
|
|
|
2017-05-19 03:14:51 -05:00
|
|
|
protected:
|
2019-09-06 03:40:57 -05:00
|
|
|
void defineUiOrdering( QString uiConfigName, caf::PdmUiOrdering& uiOrdering ) override;
|
2020-02-12 04:43:15 -06:00
|
|
|
void fieldChangedByUi( const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue ) override;
|
2019-09-06 03:40:57 -05:00
|
|
|
void defineUiTreeOrdering( caf::PdmUiTreeOrdering& uiTreeOrdering, QString uiConfigName = "" ) override;
|
2023-02-26 03:48:40 -06:00
|
|
|
void defineEditorAttribute( const caf::PdmFieldHandle* field, QString uiConfigName, caf::PdmUiEditorAttribute* attribute ) override;
|
2018-10-26 05:09:29 -05:00
|
|
|
void initAfterRead() override;
|
2017-05-19 03:14:51 -05:00
|
|
|
|
2017-05-11 06:33:18 -05:00
|
|
|
private:
|
2019-09-06 03:40:57 -05:00
|
|
|
caf::PdmField<double> m_startMD;
|
|
|
|
caf::PdmField<double> m_endMD;
|
|
|
|
caf::PdmField<double> m_diameter;
|
|
|
|
caf::PdmField<double> m_skinFactor;
|
2018-05-24 13:02:01 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
caf::PdmField<bool> m_useCustomStartDate;
|
|
|
|
caf::PdmField<QDateTime> m_startDate;
|
2018-05-24 13:02:01 -05:00
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
caf::PdmField<bool> m_useCustomEndDate;
|
|
|
|
caf::PdmField<QDateTime> m_endDate;
|
2018-05-24 13:02:01 -05:00
|
|
|
|
2018-10-10 04:10:56 -05:00
|
|
|
caf::PdmChildArrayField<RimWellPathValve*> m_valves;
|
|
|
|
|
2019-09-06 03:40:57 -05:00
|
|
|
caf::PdmField<bool> m_startOfHistory_OBSOLETE;
|
2017-05-11 06:33:18 -05:00
|
|
|
};
|