OpendTect  7.0
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Static Protected Member Functions | Protected Attributes | List of all members
Attrib::Desc Class Reference

Description of an attribute in an Attrib::DescSet. Each attribute has a name (e.g. "Similarity"), a user reference (e.g. "My similarity"), and at least one output. In addition, it may have parameters and inputs. If it has multiple outputs, only one of the outputs are selected. More...

Inheritance diagram for Attrib::Desc:
[legend]

Public Types

enum  Locality { SingleTrace , PossiblyMultiTrace , MultiTrace }
 
enum  SatisfyLevel { AllOk , Warning , Error }
 
- Public Types inherited from ObjectWithName
typedef OD::String name_type
 

Public Member Functions

 Desc (const char *attrname, DescStatusUpdater updater=0, DescDefaultsUpdater defupdater=0)
 
 Desc (const Desc &)
 
void addInput (const InputSpec &)
 
void addOutputDataType (Seis::DataType)
 
void addOutputDataTypeSameAs (int)
 
void addParam (Param *)
 
const OD::StringattribName () const
 
void changeOutputDataType (int, Seis::DataType)
 
void changeStoredID (const char *)
 
DesccloneDescAndPropagateInput (const DescID &, BufferString)
 
Seis::DataType dataType (int output=-1) const
 
DescSetdescSet () const
 
const char * errMsg () const
 
void getAncestorIDs (DescID cid, TypeSet< DescID > &, TypeSet< int > &) const
 
bool getDefStr (BufferString &) const
 
void getDependencies (TypeSet< Attrib::DescID > &) const
 
DescgetInput (int)
 
const DescgetInput (int) const
 
void getInputs (TypeSet< Attrib::DescID > &) const
 
DescID getMultiOutputInputID () const
 
ParamgetParam (const char *key)
 
const ParamgetParam (const char *key) const
 
bool getParentID (DescID cid, DescID &pid, int &) const
 
BufferString getStoredID (bool recursive=false) const
 
DescgetStoredInput () const
 
BufferString getStoredType (bool recursive=false) const
 
ValParamgetValParam (const char *key)
 
const ValParamgetValParam (const char *key) const
 
DescID id () const
 
DescID inputId (int idx) const
 
InputSpecinputSpec (int)
 
const InputSpecinputSpec (int) const
 
bool is2D () const
 
bool isHidden () const
 
bool isIdenticalTo (const Desc &, bool cmpoutput=true) const
 
bool isIdentifiedBy (const char *) const
 
bool isParamEnabled (const char *key) const
 
bool isParamRequired (const char *key) const
 
bool isPS () const
 
SatisfyLevel isSatisfied () const
 
bool isSteering () const
 
bool isStored () const
 
bool isStoredInMem () const
 
Locality locality () const
 
bool needProvInit () const
 
int nrInputs () const
 
int nrOutputs () const
 
bool parseDefStr (const char *)
 
bool removeInput (int idx)
 
void removeOutputs ()
 
int selectedOutput () const
 
void selectOutput (int)
 
void set2D (bool yn)
 
void setDescSet (DescSet *)
 
void setErrMsg (const char *str)
 
void setHidden (bool yn)
 
bool setInput (int, const Desc *)
 
void setLocality (Locality l)
 
void setNeedProvInit (bool yn=true)
 
void setNrOutputs (Seis::DataType, int)
 
void setParamEnabled (const char *key, bool yn=true)
 
void setParamRequired (const char *key, bool yn=true)
 
void setPS (bool yn)
 
void setSteering (bool yn)
 
void setUserRef (const char *)
 
void setUsesTrcPos (bool yn)
 
void updateDefaultParams ()
 
void updateParams ()
 
const char * userRef () const
 
bool usesTracePosition () const
 
- Public Member Functions inherited from SharedObject
 SharedObject (const char *nm=nullptr)
 
 SharedObject (const SharedObject &)
 
- Public Member Functions inherited from NamedCallBacker
 NamedCallBacker (const char *nm=0)
 
 NamedCallBacker (const NamedCallBacker &)
 
virtual Notifier< NamedCallBacker > & objectToBeDeleted () const
 
bool operator== (const NamedCallBacker &oth) const
 
bool operator== (const NamedObject &oth) const
 
- Public Member Functions inherited from CallBacker
 CallBacker ()
 
 CallBacker (const CallBacker &)
 
virtual ~CallBacker ()
 
bool attachCB (const NotifierAccess &, const CallBack &, bool onlyifnew=false) const
 
bool attachCB (const NotifierAccess *notif, const CallBack &cb, bool onlyifnew=false) const
 
void detachAllNotifiers () const
 Call from the destructor of your inherited object. More...
 
void detachCB (const NotifierAccess &, const CallBack &) const
 
void detachCB (const NotifierAccess *notif, const CallBack &cb) const
 
virtual bool isCapsule () const
 
bool isNotifierAttached (const NotifierAccess *) const
 Only for debugging purposes, don't use. More...
 
void stopReceivingNotifications () const
 
virtual CallBackertrueCaller ()
 
- Public Member Functions inherited from NamedObject
 NamedObject (const char *nm=nullptr)
 
 NamedObject (const NamedObject &oth)
 
virtual ~NamedObject ()
 
virtual BufferString getName () const
 
bool getNameFromPar (const IOPar &)
 
const name_typename () const override
 
NamedObjectoperator= (const NamedObject &)
 
bool operator== (const NamedObject &oth) const
 
virtual void setName (const char *nm)
 
- Public Member Functions inherited from ObjectWithName
virtual ~ObjectWithName ()
 
bool hasName (const char *nm) const
 
bool hasName (const name_type &nm) const
 
void putNameInPar (IOPar &) const
 
- Public Member Functions inherited from RefCount::Referenced
void addObserver (WeakPtrBase *obs)
 Not for normal use. May become private. More...
 
int nrRefs () const
 Only for expert use. More...
 
void ref () const
 
bool refIfReffed () const
 Don't use in production, for debugging. More...
 
void removeObserver (WeakPtrBase *obs)
 Not for normal use. May become private. More...
 
bool tryRef () const
 Not for normal use. May become private. More...
 
void unRef () const
 
void unRefNoDelete () const
 

Static Public Member Functions

static bool getAttribName (const char *defstr, BufferString &)
 
static void getKeysValsPublic (const char *defstr, BufferStringSet &keys, BufferStringSet &vals, const char *onlyneedkey=0)
 
static bool getParamString (const char *defstr, const char *key, BufferString &)
 
static const char * sKeyAll ()
 
static const char * sKeyCrlDipComp ()
 
static const char * sKeyInlDipComp ()
 
static const char * sKeyLineDipComp ()
 
static const char * sKeyOutput ()
 
- Static Public Member Functions inherited from SharedObject
static Notifier< SharedObject > & instanceCreated ()
 
- Static Public Member Functions inherited from CallBacker
static void createReceiverForCurrentThread ()
 
static void removeReceiverForCurrentThread ()
 
- Static Public Member Functions inherited from RefCount::Referenced
static bool isSane (const Referenced *)
 

Protected Member Functions

virtual ~Desc ()
 
ParamfindParam (const char *key)
 
bool setInput_ (int, Desc *)
 
- Protected Member Functions inherited from SharedObject
virtual ~SharedObject ()
 
- Protected Member Functions inherited from NamedCallBacker
void sendDelNotif () const
 
- Protected Member Functions inherited from RefCount::Referenced
 Referenced ()
 
 Referenced (const Referenced &)
 
virtual ~Referenced ()
 
Referencedoperator= (const Referenced &)
 

Static Protected Member Functions

static void getKeysVals (const char *defstr, BufferStringSet &keys, BufferStringSet &vals, const char *onlyneedkey=0)
 

Protected Attributes

BufferString attribname_
 
DescDefaultsUpdater defaultsupdater_
 
DescSetdescset_
 
BufferString errmsg_
 
bool hidden_
 
ObjectSet< Descinputs_
 
TypeSet< InputSpecinputspecs_
 
bool is2d_
 
bool isps_
 
bool issteering_
 
Locality locality_
 
bool needprovinit_
 
TypeSet< int > outputtypelinks_
 
TypeSet< Seis::DataTypeoutputtypes_
 
ObjectSet< Paramparams_
 
int seloutput_
 
DescStatusUpdater statusupdater_
 
BufferString userref_
 
bool usestrcpos_
 
- Protected Attributes inherited from NamedCallBacker
Threads::Atomic< bool > delalreadytriggered_
 
Notifier< NamedCallBackerdelnotif_
 
- Protected Attributes inherited from NamedObject
BufferString name_
 

Detailed Description

Description of an attribute in an Attrib::DescSet. Each attribute has a name (e.g. "Similarity"), a user reference (e.g. "My similarity"), and at least one output. In addition, it may have parameters and inputs. If it has multiple outputs, only one of the outputs are selected.

The attrib name, the parameters and the selected output number together form a definition string that defines what the attribute calculates.

Each Desc has DescID that is unique within it's DescSet.

<>

Member Enumeration Documentation

◆ Locality

Enumerator
SingleTrace 
PossiblyMultiTrace 
MultiTrace 

◆ SatisfyLevel

Enumerator
AllOk 
Warning 
Error 

Constructor & Destructor Documentation

◆ Desc() [1/2]

Attrib::Desc::Desc ( const Desc )

◆ Desc() [2/2]

Attrib::Desc::Desc ( const char *  attrname,
DescStatusUpdater  updater = 0,
DescDefaultsUpdater  defupdater = 0 
)

◆ ~Desc()

virtual Attrib::Desc::~Desc ( )
protectedvirtual

Member Function Documentation

◆ addInput()

void Attrib::Desc::addInput ( const InputSpec )

◆ addOutputDataType()

void Attrib::Desc::addOutputDataType ( Seis::DataType  )

◆ addOutputDataTypeSameAs()

void Attrib::Desc::addOutputDataTypeSameAs ( int  )

◆ addParam()

void Attrib::Desc::addParam ( Param )

Pointer becomes mine

◆ attribName()

const OD::String& Attrib::Desc::attribName ( ) const

◆ changeOutputDataType()

void Attrib::Desc::changeOutputDataType ( int  ,
Seis::DataType   
)

◆ changeStoredID()

void Attrib::Desc::changeStoredID ( const char *  )

◆ cloneDescAndPropagateInput()

Desc* Attrib::Desc::cloneDescAndPropagateInput ( const DescID ,
BufferString   
)

◆ dataType()

Seis::DataType Attrib::Desc::dataType ( int  output = -1) const
Parameters
outputspecifies which output is required, or -1 for the selected output.

◆ descSet()

DescSet* Attrib::Desc::descSet ( ) const

◆ errMsg()

const char* Attrib::Desc::errMsg ( ) const

◆ findParam()

Param* Attrib::Desc::findParam ( const char *  key)
protected

◆ getAncestorIDs()

void Attrib::Desc::getAncestorIDs ( DescID  cid,
TypeSet< DescID > &  ,
TypeSet< int > &   
) const

◆ getAttribName()

static bool Attrib::Desc::getAttribName ( const char *  defstr,
BufferString  
)
static

◆ getDefStr()

bool Attrib::Desc::getDefStr ( BufferString ) const

◆ getDependencies()

void Attrib::Desc::getDependencies ( TypeSet< Attrib::DescID > &  ) const

Generates list of attributes this attribute is dependant on.

◆ getInput() [1/2]

Desc* Attrib::Desc::getInput ( int  )

◆ getInput() [2/2]

const Desc* Attrib::Desc::getInput ( int  ) const

◆ getInputs()

void Attrib::Desc::getInputs ( TypeSet< Attrib::DescID > &  ) const

◆ getKeysVals()

static void Attrib::Desc::getKeysVals ( const char *  defstr,
BufferStringSet keys,
BufferStringSet vals,
const char *  onlyneedkey = 0 
)
staticprotected

Fills keys and vals with pairs of parameters from the defstr.

◆ getKeysValsPublic()

static void Attrib::Desc::getKeysValsPublic ( const char *  defstr,
BufferStringSet keys,
BufferStringSet vals,
const char *  onlyneedkey = 0 
)
inlinestatic

Fills keys and vals with pairs of parameters from the defstr.

◆ getMultiOutputInputID()

DescID Attrib::Desc::getMultiOutputInputID ( ) const

◆ getParam() [1/2]

Param* Attrib::Desc::getParam ( const char *  key)

◆ getParam() [2/2]

const Param* Attrib::Desc::getParam ( const char *  key) const

◆ getParamString()

static bool Attrib::Desc::getParamString ( const char *  defstr,
const char *  key,
BufferString  
)
static

◆ getParentID()

bool Attrib::Desc::getParentID ( DescID  cid,
DescID pid,
int &   
) const

◆ getStoredID()

BufferString Attrib::Desc::getStoredID ( bool  recursive = false) const

◆ getStoredInput()

Desc* Attrib::Desc::getStoredInput ( ) const

◆ getStoredType()

BufferString Attrib::Desc::getStoredType ( bool  recursive = false) const

◆ getValParam() [1/2]

ValParam* Attrib::Desc::getValParam ( const char *  key)

◆ getValParam() [2/2]

const ValParam* Attrib::Desc::getValParam ( const char *  key) const

◆ id()

DescID Attrib::Desc::id ( ) const

◆ inputId()

DescID Attrib::Desc::inputId ( int  idx) const

◆ inputSpec() [1/2]

InputSpec& Attrib::Desc::inputSpec ( int  )

◆ inputSpec() [2/2]

const InputSpec& Attrib::Desc::inputSpec ( int  ) const

◆ is2D()

bool Attrib::Desc::is2D ( ) const
inline

◆ isHidden()

bool Attrib::Desc::isHidden ( ) const
inline

If hidden, it won't show up in UI.

◆ isIdenticalTo()

bool Attrib::Desc::isIdenticalTo ( const Desc ,
bool  cmpoutput = true 
) const

◆ isIdentifiedBy()

bool Attrib::Desc::isIdentifiedBy ( const char *  ) const

◆ isParamEnabled()

bool Attrib::Desc::isParamEnabled ( const char *  key) const

◆ isParamRequired()

bool Attrib::Desc::isParamRequired ( const char *  key) const

◆ isPS()

bool Attrib::Desc::isPS ( ) const
inline

◆ isSatisfied()

SatisfyLevel Attrib::Desc::isSatisfied ( ) const

Checks whether all inputs are satisfied.

◆ isSteering()

bool Attrib::Desc::isSteering ( ) const
inline

◆ isStored()

bool Attrib::Desc::isStored ( ) const

◆ isStoredInMem()

bool Attrib::Desc::isStoredInMem ( ) const

◆ locality()

Locality Attrib::Desc::locality ( ) const
inline

◆ needProvInit()

bool Attrib::Desc::needProvInit ( ) const
inline

◆ nrInputs()

int Attrib::Desc::nrInputs ( ) const

◆ nrOutputs()

int Attrib::Desc::nrOutputs ( ) const

◆ parseDefStr()

bool Attrib::Desc::parseDefStr ( const char *  )

◆ removeInput()

bool Attrib::Desc::removeInput ( int  idx)

◆ removeOutputs()

void Attrib::Desc::removeOutputs ( )

◆ selectedOutput()

int Attrib::Desc::selectedOutput ( ) const

◆ selectOutput()

void Attrib::Desc::selectOutput ( int  )

◆ set2D()

void Attrib::Desc::set2D ( bool  yn)
inline

◆ setDescSet()

void Attrib::Desc::setDescSet ( DescSet )

◆ setErrMsg()

void Attrib::Desc::setErrMsg ( const char *  str)
inline

◆ setHidden()

void Attrib::Desc::setHidden ( bool  yn)
inline

If hidden, it won't show up in UI.

◆ setInput()

bool Attrib::Desc::setInput ( int  ,
const Desc  
)

◆ setInput_()

bool Attrib::Desc::setInput_ ( int  ,
Desc  
)
protected

◆ setLocality()

void Attrib::Desc::setLocality ( Locality  l)
inline

◆ setNeedProvInit()

void Attrib::Desc::setNeedProvInit ( bool  yn = true)
inline

◆ setNrOutputs()

void Attrib::Desc::setNrOutputs ( Seis::DataType  ,
int   
)

◆ setParamEnabled()

void Attrib::Desc::setParamEnabled ( const char *  key,
bool  yn = true 
)

◆ setParamRequired()

void Attrib::Desc::setParamRequired ( const char *  key,
bool  yn = true 
)

◆ setPS()

void Attrib::Desc::setPS ( bool  yn)
inline

◆ setSteering()

void Attrib::Desc::setSteering ( bool  yn)
inline

◆ setUserRef()

void Attrib::Desc::setUserRef ( const char *  )

◆ setUsesTrcPos()

void Attrib::Desc::setUsesTrcPos ( bool  yn)
inline

◆ sKeyAll()

static const char* Attrib::Desc::sKeyAll ( )
static

◆ sKeyCrlDipComp()

static const char* Attrib::Desc::sKeyCrlDipComp ( )
static

◆ sKeyInlDipComp()

static const char* Attrib::Desc::sKeyInlDipComp ( )
static

◆ sKeyLineDipComp()

static const char* Attrib::Desc::sKeyLineDipComp ( )
static

◆ sKeyOutput()

static const char* Attrib::Desc::sKeyOutput ( )
static

◆ updateDefaultParams()

void Attrib::Desc::updateDefaultParams ( )

◆ updateParams()

void Attrib::Desc::updateParams ( )

◆ userRef()

const char* Attrib::Desc::userRef ( ) const

◆ usesTracePosition()

bool Attrib::Desc::usesTracePosition ( ) const
inline

Member Data Documentation

◆ attribname_

BufferString Attrib::Desc::attribname_
protected

◆ defaultsupdater_

DescDefaultsUpdater Attrib::Desc::defaultsupdater_
protected

◆ descset_

DescSet* Attrib::Desc::descset_
protected

◆ errmsg_

BufferString Attrib::Desc::errmsg_
protected

◆ hidden_

bool Attrib::Desc::hidden_
protected

◆ inputs_

ObjectSet<Desc> Attrib::Desc::inputs_
protected

◆ inputspecs_

TypeSet<InputSpec> Attrib::Desc::inputspecs_
protected

◆ is2d_

bool Attrib::Desc::is2d_
protected

◆ isps_

bool Attrib::Desc::isps_
protected

◆ issteering_

bool Attrib::Desc::issteering_
protected

◆ locality_

Locality Attrib::Desc::locality_
protected

◆ needprovinit_

bool Attrib::Desc::needprovinit_
protected

◆ outputtypelinks_

TypeSet<int> Attrib::Desc::outputtypelinks_
protected

◆ outputtypes_

TypeSet<Seis::DataType> Attrib::Desc::outputtypes_
protected

◆ params_

ObjectSet<Param> Attrib::Desc::params_
protected

◆ seloutput_

int Attrib::Desc::seloutput_
protected

◆ statusupdater_

DescStatusUpdater Attrib::Desc::statusupdater_
protected

◆ userref_

BufferString Attrib::Desc::userref_
protected

◆ usestrcpos_

bool Attrib::Desc::usestrcpos_
protected

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