15 #include "generalmod.h" 69 { add( spec.
clone() ); }
74 { specs_ += spec.
clone();
return *
this; }
81 Form* ret =
new Form( nm, *specs_[0] );
82 for (
int idx=1; idx<specs_.size(); idx++ )
83 ret->
specs_ += specs_[idx]->clone();
93 : NamedObject(nm), req_(rs)
99 : NamedObject(nm), req_(rs), proptype_(p)
104 : NamedObject(nm), req_(rs), proptype_(p)
110 { forms_ +=
new Form( nm, spec );
return *
this; }
112 { forms_ +=
new Form( nm, spec );
return *
this; }
114 { forms_ += frm;
return *
this; }
123 const Form&
form(
int idx )
const {
return *forms_[idx]; }
126 for (
int idx=0; idx<forms_.size(); idx++ )
127 if ( forms_[idx]->name() == formnm )
145 : pos_(rc), keyword_(kw) {}
147 : pos_(0,-1), val_(s) {}
150 {
return pos_.col() >= 0; }
152 {
return isInFile() && !keyword_.isEmpty();}
154 {
return !val_.isEmpty(); }
156 {
return !isInFile() && !isSpecified();}
158 {
return pos_ == v.
pos_ && val_ == v.
val_ 172 : form_(0), unit_(0), coordsys_(0) {}
175 {
return ielem < elems_.
size()
176 && elems_[ielem].isInFile(); }
178 {
return ielem < elems_.
size()
179 && elems_[ielem].isKeyworded(); }
181 {
return ielem < elems_.
size()
182 && elems_[ielem].isInFile(); }
184 {
return ielem >= elems_.
size() ? 0
185 : elems_[ielem].val_.buf(); }
187 {
return elems_.
size() > 0 && !elems_[0].
isEmpty(); }
195 static TargetInfo* mkHorPosition(
bool isreq,
bool wic=
true,
bool wll=
false,
199 {
return mkZPos(isreq,withunits); }
201 {
return mkZPos(isreq,withunits,1); }
203 {
return mkZPos(isreq,withunits,-1); }
204 bool needsConversion()
const;
213 static TargetInfo* mkZPos(
bool,
bool wu=
false,
int zopt=0);
226 , eohtokencol_(-1) {}
239 {
return nrhdrlines_ < 0 && !eohtoken_.
isEmpty(); }
241 {
return needEOHToken() ?
mUdf(
int)
242 : nrhdrlines_ > 0 ? nrhdrlines_ : 0; }
244 {
return !eobtoken_.
isEmpty(); }
247 bool bodyUsesCol(
int)
const;
254 nrhdrlines_ = eohtokencol_ = 0;
ReqSpec
Definition: tabledef.h:28
#define mExpClass(module)
Definition: commondefs.h:160
bool isHidden() const
Definition: tabledef.h:117
ObjectSet< Form > forms_
Definition: tabledef.h:211
const Form & form(int idx) const
Definition: tabledef.h:123
bool havePos(int ielem) const
Definition: tabledef.h:174
TargetInfo(const char *nm, const DataInpSpec &spec, ReqSpec rs=Optional, PropertyRef::StdType p=PropertyRef::Other)
Definition: tabledef.h:101
bool operator==(const ArrayNDInfo &a1, const ArrayNDInfo &a2)
Definition: arrayndinfo.h:53
TypeSet< Elem > elems_
Definition: tabledef.h:167
virtual DataInpSpec * clone() const =0
static TargetInfo * mkTimePosition(bool isreq, bool withunits=true)
Definition: tabledef.h:202
static TargetInfo * mkZPosition(bool isreq, bool withunits=true)
Definition: tabledef.h:198
void usePar(const IOPar &iop, ODPolygon< T > &poly, const char *inpkey)
Definition: polygon.h:188
RowCol pos_
Definition: tabledef.h:161
Selected element/positioning This selects the specific form and where/how it can be found in the file...
Definition: tabledef.h:137
Ref Data for a (usually petrophysical) property.
Definition: propertyref.h:42
BufferString & setEmpty()
PropertyRef::StdType proptype_
Definition: tabledef.h:210
bool isEmpty() const
Definition: odset.h:45
A cartesian coordinate in 2D space.
Definition: coord.h:25
Selection selection_
Definition: tabledef.h:190
bool isSpecified() const
Definition: tabledef.h:153
TargetInfo & add(const char *nm, const DataInpSpec &spec)
Definition: tabledef.h:111
int form_
Definition: tabledef.h:166
Specifications for character string inputs.
Definition: datainpspec.h:577
Definition: tabledef.h:28
ReqSpec req_
Definition: tabledef.h:209
Definition: propertyref.h:49
Set of (small) copyable elements.
Definition: commontypes.h:30
Generalized set of parameters of the keyword-value type.
Definition: iopar.h:47
Specification of input characteristics.
Definition: datainpspec.h:89
Definition: geom2dascio.h:21
void setPropertyType(PropertyRef::StdType p)
Definition: tabledef.h:119
static TargetInfo * mkDepthPosition(bool isreq, bool withunits=true)
Definition: tabledef.h:200
#define mUdf(type)
Use this macro to get the undefined for simple types.
Definition: undefval.h:272
const UnitOfMeasure * unit_
Definition: tabledef.h:168
bool isFilled() const
Definition: tabledef.h:186
Definition: tabledef.h:28
TargetInfo(const char *nm, ReqSpec rs=Optional)
Definition: tabledef.h:91
TargetInfo(const char *nm, DataInpSpec *spec, ReqSpec rs=Optional, PropertyRef::StdType p=PropertyRef::Other)
Definition: tabledef.h:96
Selection()
Definition: tabledef.h:171
int formNr(const char *formnm) const
Definition: tabledef.h:124
BufferString keyword_
Definition: tabledef.h:162
void fillPar(IOPar &iop, const ODPolygon< T > &poly, const char *inpkey)
Definition: polygon.h:175
Definition: tabledef.h:28
~TargetInfo()
Definition: tabledef.h:107
BufferString val_
Definition: tabledef.h:163
IdxPair used for its row() and col().
Definition: rowcol.h:25
Elem(const char *s)
Definition: tabledef.h:146
bool isOptional() const
Definition: tabledef.h:116
TargetInfo & add(const char *nm, DataInpSpec *spec=0)
Definition: tabledef.h:109
OD::String with its own variable length buffer. The buffer has a guaranteed minimum size...
Definition: bufstring.h:40
T convert(Type inptyp, T val, Type outtyp)
Definition: angles.h:76
const char * getVal(int ielem) const
Definition: tabledef.h:183
bool isEmpty() const
Definition: odstring.h:51
bool isKeyworded(int ielem) const
Definition: tabledef.h:177
PropertyRef::StdType propertyType() const
Definition: tabledef.h:118
Form & form(int idx)
Definition: tabledef.h:122
Object with a name.
Definition: namedobj.h:35
Elem(const RowCol &rc, const char *kw=0)
Definition: tabledef.h:144
bool isInFile() const
Definition: tabledef.h:149
bool isInFile(int ielem=0) const
Definition: tabledef.h:180
int nrForms() const
Definition: tabledef.h:121
ConstRefMan< Coords::CoordSystem > coordsys_
Definition: tabledef.h:169
Elem()
Definition: tabledef.h:142
TargetInfo & add(Form *frm)
Definition: tabledef.h:113
StdType
Definition: propertyref.h:46
Description of a Logical piece of information.
Definition: tabledef.h:42
holds the 'value' of a certain selection
Definition: tabledef.h:140
Unit of Measure.
Definition: unitofmeasure.h:35
bool isEmpty() const
Definition: tabledef.h:155
bool isKeyworded() const
Definition: tabledef.h:151
void deepErase(ObjectSet< T > &os)
empty the ObjectSet deleting all objects pointed to.
Definition: objectset.h:118