2017-05-19 15:44:32 +02:00
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
//
|
|
|
|
|
// Copyright (C) 2017 Statoil ASA
|
2019-09-06 10:40:57 +02:00
|
|
|
//
|
2017-05-19 15:44:32 +02: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 10:40:57 +02:00
|
|
|
//
|
2017-05-19 15:44:32 +02: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 10:40:57 +02:00
|
|
|
//
|
|
|
|
|
// See the GNU General Public License at <http://www.gnu.org/licenses/gpl.html>
|
2017-05-19 15:44:32 +02:00
|
|
|
// for more details.
|
|
|
|
|
//
|
|
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#include "RimCheckableNamedObject.h"
|
|
|
|
|
|
2021-01-21 12:58:46 +01:00
|
|
|
#include "RiaDefines.h"
|
2017-06-20 10:40:39 +02:00
|
|
|
|
2017-05-19 15:44:32 +02:00
|
|
|
#include "cafPdmChildArrayField.h"
|
|
|
|
|
#include "cafPdmChildField.h"
|
2019-09-06 10:40:57 +02:00
|
|
|
#include "cafPdmFieldCvfColor.h"
|
2017-05-23 09:35:17 +02:00
|
|
|
|
|
|
|
|
#include "cvfColor3.h"
|
2017-05-19 15:44:32 +02:00
|
|
|
|
2021-02-26 14:27:59 +01:00
|
|
|
class RimFishbones;
|
2017-05-19 15:44:32 +02:00
|
|
|
|
|
|
|
|
//==================================================================================================
|
|
|
|
|
//
|
2019-09-06 10:40:57 +02:00
|
|
|
//
|
2017-05-19 15:44:32 +02:00
|
|
|
//
|
|
|
|
|
//==================================================================================================
|
|
|
|
|
class RimFishbonesCollection : public RimCheckableNamedObject
|
|
|
|
|
{
|
|
|
|
|
CAF_PDM_HEADER_INIT;
|
|
|
|
|
|
|
|
|
|
public:
|
|
|
|
|
RimFishbonesCollection();
|
|
|
|
|
|
2021-04-20 15:35:20 +02:00
|
|
|
void appendFishbonesSubs( RimFishbones* subs );
|
2017-05-19 15:44:32 +02:00
|
|
|
|
2021-02-26 14:27:59 +01:00
|
|
|
bool hasFishbones() const;
|
|
|
|
|
std::vector<RimFishbones*> activeFishbonesSubs() const;
|
|
|
|
|
std::vector<RimFishbones*> allFishbonesSubs() const;
|
2018-09-07 12:41:04 +02:00
|
|
|
|
2019-09-06 10:40:57 +02:00
|
|
|
void recalculateStartMD();
|
|
|
|
|
double startMD() const;
|
2021-02-26 14:27:59 +01:00
|
|
|
double endMD() const;
|
2020-02-12 11:13:38 +01:00
|
|
|
double mainBoreSkinFactor() const { return m_skinFactor; }
|
2021-01-21 12:58:46 +01:00
|
|
|
double mainBoreDiameter( RiaDefines::EclipseUnitSystem unitSystem ) const;
|
2019-09-06 10:40:57 +02:00
|
|
|
void setUnitSystemSpecificDefaults();
|
2017-06-20 12:36:12 +02:00
|
|
|
|
2017-05-22 11:29:13 +02:00
|
|
|
protected:
|
2020-02-12 11:43:15 +01:00
|
|
|
void fieldChangedByUi( const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue ) override;
|
2019-09-06 10:40:57 +02:00
|
|
|
void defineUiOrdering( QString uiConfigName, caf::PdmUiOrdering& uiOrdering ) override;
|
2017-05-22 11:29:13 +02:00
|
|
|
|
2017-05-19 15:44:32 +02:00
|
|
|
private:
|
2017-05-23 09:35:17 +02:00
|
|
|
cvf::Color3f nextFishbonesColor() const;
|
|
|
|
|
|
2017-06-02 14:58:33 +02:00
|
|
|
private:
|
2021-04-20 15:35:20 +02:00
|
|
|
caf::PdmChildArrayField<RimFishbones*> m_fishbones;
|
2017-06-02 14:58:33 +02:00
|
|
|
|
2021-02-26 14:27:59 +01:00
|
|
|
caf::PdmField<double> m_startMD;
|
|
|
|
|
caf::PdmField<double> m_skinFactor;
|
|
|
|
|
caf::PdmField<double> m_mainBoreDiameter;
|
|
|
|
|
bool manuallyModifiedStartMD;
|
2017-05-19 15:44:32 +02:00
|
|
|
};
|