OpendTect-6_4  6.4
welltiesetup.h
Go to the documentation of this file.
1 #ifndef welltiesetup_h
2 #define welltiesetup_h
3 
4 /*+
5 ________________________________________________________________________
6 
7  (C) dGB Beheer B.V.; (LICENSE) http://opendtect.org/OpendTect_license.txt
8  Author: Bruno
9  Date: Jan 2009
10  RCS: $Id$
11 ________________________________________________________________________
12 
13 -*/
14 
15 #include "wellattribmod.h"
16 #include "namedobj.h"
17 
18 #include "enums.h"
19 #include "multiid.h"
20 #include "wellio.h"
21 #include "od_iosfwd.h"
22 
23 
24 #define mIsUnvalidD2TM(wd) ( !wd.haveD2TModel() || wd.d2TModel()->size()<2 )
25 
26 namespace WellTie
27 {
28 
29 mExpClass(WellAttrib) Setup
31 public:
32  enum CorrType { None, Automatic, UserDefined };
34 
35  Setup()
36  : wellid_(-1)
37  , seisid_()
38  , wvltid_(-1)
39  , linenm_(*new BufferString) //empty = data is 3D
40  , issonic_(true)
41  , useexistingd2tm_(true)
42  , corrtype_(Automatic)
43  {}
44 
45 
46  Setup( const Setup& setup )
47  : wellid_(setup.wellid_)
48  , seisid_(setup.seisid_)
49  , wvltid_(setup.wvltid_)
50  , linenm_(setup.linenm_)
51  , issonic_(setup.issonic_)
52  , seisnm_(setup.seisnm_)
53  , vellognm_(setup.vellognm_)
54  , denlognm_(setup.denlognm_)
55  , useexistingd2tm_(setup.useexistingd2tm_)
56  , corrtype_(setup.corrtype_)
57  {}
58 
66  bool issonic_;
68  CorrType corrtype_;
69 
70  void supportOldPar(const IOPar&);
71  void usePar(const IOPar&);
72  void fillPar(IOPar&) const;
73 
74  static Setup& defaults();
75  static void commitDefaults();
76 
77  static const char* sKeyCSCorrType()
78  { return "CheckShot Corrections"; }
79  static const char* sKeyUseExistingD2T()
80  { return "Use Existing Depth/Time model"; }
81  static const uiString sCSCorrType()
82  { return tr("CheckShot Corrections"); }
83  static const uiString sUseExistingD2T()
84  { return tr("Use Existing Depth/Time model"); }
85 };
86 
87 
88 mExpClass(WellAttrib) IO : public Well::odIO
89 {
90 public:
91  IO( const char* f, BufferString& errmsg )
92  : Well::odIO(f,errmsg) {}
93 
94  static const char* sKeyWellTieSetup();
95 
96 };
97 
98 
99 mExpClass(WellAttrib) Writer : public IO
100 {
101 public:
102  Writer( const char* f )
103  : IO(f,errmsg_) {}
104 
105  bool putWellTieSetup(const WellTie::Setup&) const;
106 
107  bool putIOPar(const IOPar&,const char*) const;
108 
109 protected:
110 
112 
113  bool putIOPar(const IOPar&,const char*,
114  od_ostream&) const;
115  bool wrHdr(od_ostream&,const char*) const;
116 
117 };
118 
119 
120 mExpClass(WellAttrib) Reader : public IO
121 {
122 public:
123  Reader( const char* f )
124  : IO(f,errmsg_) {}
125 
126  void getWellTieSetup(WellTie::Setup&) const;
127 
128  IOPar* getIOPar(const char*) const;
129 
130 protected:
131 
133 
134  IOPar* getIOPar(const char*,od_istream&) const;
135 
136 };
137 
138 } // namespace WellTie
139 
140 #endif
#define mExpClass(module)
Definition: commondefs.h:160
IO(const char *f, BufferString &errmsg)
Definition: welltiesetup.h:91
OD class for stream write common access to the user log file, or std::cout in batch progs...
Definition: od_ostream.h:26
#define mODTextTranslationClass(clss)
Definition: uistring.h:38
bool issonic_
Definition: welltiesetup.h:66
Definition: welltiesetup.h:29
static const char * sKeyUseExistingD2T()
Definition: welltiesetup.h:79
void usePar(const IOPar &iop, ODPolygon< T > &poly, const char *inpkey)
Definition: polygon.h:188
Definition: welltiesetup.h:88
MultiID wellid_
Definition: welltiesetup.h:59
BufferString seisnm_
Definition: welltiesetup.h:63
mODTextTranslationClass(Setup) public mDeclareEnumUtils(CorrType) Setup()
Definition: welltiesetup.h:33
Definition: uistring.h:89
Definition: welltiecshot.h:21
FixedString None()
Definition: keystrs.h:90
OD class for stream read.
Definition: od_istream.h:24
BufferString vellognm_
Definition: welltiesetup.h:64
CorrType corrtype_
Definition: welltiesetup.h:68
MultiID wvltid_
Definition: welltiesetup.h:61
Generalized set of parameters of the keyword-value type.
Definition: iopar.h:47
BufferString denlognm_
Definition: welltiesetup.h:65
bool useexistingd2tm_
Definition: welltiesetup.h:67
MultiID seisid_
Definition: welltiesetup.h:60
static const uiString sCSCorrType()
Definition: welltiesetup.h:81
BufferString errmsg_
Definition: welltiesetup.h:132
Definition: directionalsurvey.h:19
BufferString errmsg_
Definition: welltiesetup.h:111
Setup(const Setup &setup)
Definition: welltiesetup.h:46
void fillPar(IOPar &iop, const ODPolygon< T > &poly, const char *inpkey)
Definition: polygon.h:175
Writer(const char *f)
Definition: welltiesetup.h:102
static const char * sKeyCSCorrType()
Definition: welltiesetup.h:77
OD::String with its own variable length buffer. The buffer has a guaranteed minimum size...
Definition: bufstring.h:40
Definition: welltiesetup.h:120
BufferString errmsg_
Definition: horizontracker.h:119
Reader(const char *f)
Definition: welltiesetup.h:123
static const uiString sUseExistingD2T()
Definition: welltiesetup.h:83
Definition: welltiesetup.h:99
Compound key consisting of ints.
Definition: multiid.h:25
BufferString linenm_
Definition: welltiesetup.h:62

Generated at for the OpendTect seismic interpretation project. Copyright (C): dGB Beheer B. V. 2019