OpendTect-6_4  6.4
seispreload.h
Go to the documentation of this file.
1 #ifndef seispreload_h
2 #define seispreload_h
3 
4 /*+
5 ________________________________________________________________________
6 
7  (C) dGB Beheer B.V.; (LICENSE) http://opendtect.org/OpendTect_license.txt
8  Author: Bert
9  Date: Feb 2009
10  RCS: $Id$
11 ________________________________________________________________________
12 
13 
14 -*/
15 
16 #include "seismod.h"
17 #include "bufstringset.h"
18 #include "datachar.h"
19 #include "datapackbase.h"
20 #include "multiid.h"
21 #include "ranges.h"
22 #include "task.h"
23 
24 class IOObj;
25 class Scaler;
26 class TrcKeyZSampling;
27 
28 namespace Seis
29 {
30 
32 { mODTextTranslationClass(PreLoader)
33 public:
34  PreLoader(const MultiID&,Pos::GeomID =-1,
35  TaskRunner* =0);
36 
37  const MultiID& id() const { return mid_; }
38  Pos::GeomID geomID() const { return geomid_; }
39  void setTaskRunner( TaskRunner& t ) { tr_ = &t; }
40 
41  IOObj* getIOObj() const;
42  Interval<int> inlRange() const;
44  void getLineNames(BufferStringSet&) const;
46 
47  bool load(const TrcKeyZSampling&,
50  Scaler* =0) const;
51  bool load(const TypeSet<TrcKeyZSampling>&,
52  const TypeSet<Pos::GeomID>&,
55  Scaler* =0) const;
56  bool loadPS3D(const Interval<int>* inlrg=0) const;
57  bool loadPS2D(const char* lnm=0) const;
58  bool loadPS2D(const BufferStringSet&) const;
59 
60  void unLoad() const;
61  uiString errMsg() const { return errmsg_; }
62 
63  static void load(const IOPar&,TaskRunner* tr=0);
65  static void loadObj(const IOPar&,TaskRunner* tr=0);
67  void fillPar(IOPar&) const;
68 
69  static const char* sKeyLines();
70  static const char* sKeyUserType();
71 
72 protected:
73 
78  mutable uiString errmsg_;
79 
80  TaskRunner& getTr() const
81  { return *((TaskRunner*)(tr_ ? tr_ : &deftr_)); }
82 };
83 
84 
86 {
87 public:
88  PreLoadDataEntry(const MultiID&,Pos::GeomID,int dpid);
89 
90  bool equals(const MultiID&,Pos::GeomID) const;
91 
94  int dpid_;
95  bool is2d_;
97 };
98 
99 
101 {
102 public:
103  void add(const MultiID&,DataPack*);
104  void add(const MultiID&,Pos::GeomID,DataPack*);
105  void remove(const MultiID&,Pos::GeomID =-1);
106  void remove(int dpid);
107  void removeAll();
108 
109  DataPack* get(const MultiID&,Pos::GeomID =-1);
110  DataPack* get(int dpid);
111  const DataPack* get(const MultiID&,Pos::GeomID =-1) const;
112  const DataPack* get(int dpid) const;
113  void getInfo(const MultiID&,Pos::GeomID,
114  BufferString&) const;
115 
116  void getIDs(TypeSet<MultiID>&) const;
117  bool isPresent(const MultiID&,Pos::GeomID =-1) const;
118 
119  const ObjectSet<PreLoadDataEntry>& getEntries() const;
120 
122 
123 protected:
124 
127 
128 public:
131 };
132 
134 
135 } // namespace Seis
136 
137 #endif
#define mExpClass(module)
Definition: commondefs.h:160
Summary for a Seismic object.
Definition: segydirectdef.h:23
To be able to send and/or receive CallBacks, inherit from this class.
Definition: callback.h:272
ManagedObjectSet< PreLoadDataEntry > entries_
Definition: seispreload.h:126
Pos::GeomID geomid_
Definition: seispreload.h:93
Pos::GeomID geomid_
Definition: seispreload.h:75
Definition: ioobj.h:58
TaskRunner * tr_
Definition: seispreload.h:76
int dpid_
Definition: seispreload.h:94
#define mODTextTranslationClass(clss)
Definition: uistring.h:38
#define mGlobal(module)
Definition: commondefs.h:163
DataPackMgr & dpmgr_
Definition: seispreload.h:125
Definition: seispreload.h:85
MultiID mid_
Definition: seispreload.h:92
Definition: uistring.h:89
Set of BufferString objects.
Definition: bufstringset.h:28
uiString errMsg() const
Definition: seispreload.h:61
mODTextTranslationClass(PreLoader) public const MultiID & id() const
Definition: seispreload.h:37
A data packet: data+positioning and more that needs to be shared.
Definition: datapack.h:34
Definition: callback.h:254
Set of pointers to objects.
Definition: commontypes.h:32
Notifier< PreLoadDataManager > changed
Definition: seispreload.h:121
Manages DataPacks.
Definition: datapack.h:141
TaskRunner & getTr() const
Definition: seispreload.h:80
BufferString name_
Definition: seispreload.h:96
void removeAll()
Generalized set of parameters of the keyword-value type.
Definition: iopar.h:47
Class that can execute a task.
Definition: task.h:169
Hor+Vert sampling in 3D surveys.
Definition: trckeyzsampling.h:35
Definition: seispreload.h:100
uiString errmsg_
Definition: seispreload.h:78
Scaling of floating point numbers.
Definition: scaler.h:33
void fillPar(IOPar &iop, const ODPolygon< T > &poly, const char *inpkey)
Definition: polygon.h:175
Definition: seispreload.h:31
bool is2d_
Definition: seispreload.h:95
Index_Type GeomID
Definition: commontypes.h:52
Definition: datachar.h:88
OD::String with its own variable length buffer. The buffer has a guaranteed minimum size...
Definition: bufstring.h:40
PreLoadDataManager & PLDM()
BufferString errmsg_
Definition: horizontracker.h:119
MultiID mid_
Definition: seispreload.h:74
void setTaskRunner(TaskRunner &t)
Definition: seispreload.h:39
UserType
Definition: datachar.h:88
ObjectSet where the objects contained are owned by this set.
Definition: manobjectset.h:23
TaskRunner deftr_
Definition: seispreload.h:77
Compound key consisting of ints.
Definition: multiid.h:25
Pos::GeomID geomID() const
Definition: seispreload.h:38

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