Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions

Attrib::Desc Class Reference

List of all members.

Public Types

enum  SatisfyLevel { AllOk, Warning, Error }

Public Member Functions

 Desc (const Desc &)
 Desc (const char *attrname, DescStatusUpdater updater=0, DescDefaultsUpdater defupdater=0)
const char * attribName () const
void setDescSet (DescSet *)
DescSetdescSet () const
DescID id () const
bool getDefStr (BufferString &) const
bool parseDefStr (const char *)
const char * userRef () const
void setUserRef (const char *)
int nrOutputs () const
void selectOutput (int)
int selectedOutput () const
Seis::DataType dataType (int output=-1) const
void setSteering (bool yn)
bool isSteering () const
void setHidden (bool yn)
bool isHidden () const
bool isStored () const
BufferString getStoredID (bool recursive=false) const
void setNeedProvInit (bool yn=true)
bool needProvInit () const
int nrInputs () const
InputSpecinputSpec (int)
const InputSpecinputSpec (int) const
bool setInput (int, const Desc *)
DescgetInput (int)
const DescgetInput (int) const
void getDependencies (TypeSet< Attrib::DescID > &) const
bool is2D () const
void set2D (bool yn)
SatisfyLevel isSatisfied () const
const char * errMsg () const
void setErrMsg (const char *str)
bool isIdenticalTo (const Desc &, bool cmpoutput=true) const
bool isIdentifiedBy (const char *) const
DescID inputId (int idx) const
void addParam (Param *)
const ParamgetParam (const char *key) const
ParamgetParam (const char *key)
const ValParamgetValParam (const char *key) const
ValParamgetValParam (const char *key)
void setParamEnabled (const char *key, bool yn=true)
bool isParamEnabled (const char *key) const
void setParamRequired (const char *key, bool yn=true)
bool isParamRequired (const char *key) const
void updateParams ()
void updateDefaultParams ()
void changeStoredID (const char *)
void addInput (const InputSpec &)
bool removeInput (int idx)
void removeOutputs ()
void addOutputDataType (Seis::DataType)
void setNrOutputs (Seis::DataType, int)
void addOutputDataTypeSameAs (int)
void changeOutputDataType (int, Seis::DataType)
DescgetStoredInput () const

Static Public Member Functions

static bool getAttribName (const char *defstr, BufferString &)
static bool getParamString (const char *defstr, const char *key, BufferString &)
static const char * sKeyInlDipComp ()
static const char * sKeyCrlDipComp ()

Protected Member Functions

bool setInput_ (int, Desc *)
ParamfindParam (const char *key)
void getKeysVals (const char *defstr, BufferStringSet &keys, BufferStringSet &vals)

Protected Attributes

TypeSet< Seis::DataTypeoutputtypes_
TypeSet< int > outputtypelinks_
bool issteering_
bool hidden_
bool needprovinit_
bool is2d_
TypeSet< InputSpecinputspecs_
ObjectSet< Descinputs_
BufferString attribname_
ObjectSet< Paramparams_
BufferString userref_
int seloutput_
DescSetdescset_
DescStatusUpdater statusupdater_
DescDefaultsUpdater defaultsupdater_
BufferString errmsg_

Private Member Functions

 mRefCountImpl (Desc)

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 define what the attribute calculates.

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


Member Enumeration Documentation

Enumerator:
AllOk 
Warning 
Error 

Constructor & Destructor Documentation

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

Member Function Documentation

void Attrib::Desc::addInput ( const InputSpec  ) 
void Attrib::Desc::addOutputDataType ( Seis::DataType   ) 
void Attrib::Desc::addOutputDataTypeSameAs ( int   ) 
void Attrib::Desc::addParam ( Param  ) 

Pointer becomes mine

const char* Attrib::Desc::attribName (  )  const
void Attrib::Desc::changeOutputDataType ( int  ,
Seis::DataType   
)
void Attrib::Desc::changeStoredID ( const char *   ) 
Seis::DataType Attrib::Desc::dataType ( int  output = -1  )  const
Parameters:
output specifies which output is required, or -1 for the selected output.
DescSet* Attrib::Desc::descSet (  )  const
const char* Attrib::Desc::errMsg (  )  const
Param* Attrib::Desc::findParam ( const char *  key  )  [protected]
static bool Attrib::Desc::getAttribName ( const char *  defstr,
BufferString  
) [static]
bool Attrib::Desc::getDefStr ( BufferString  )  const
void Attrib::Desc::getDependencies ( TypeSet< Attrib::DescID > &   )  const

Generates list of attributes this attribute is dependant on.

Desc* Attrib::Desc::getInput ( int   ) 
const Desc* Attrib::Desc::getInput ( int   )  const
void Attrib::Desc::getKeysVals ( const char *  defstr,
BufferStringSet keys,
BufferStringSet vals 
) [protected]

Fills and with pairs of parameters from the defstr.

const Param* Attrib::Desc::getParam ( const char *  key  )  const
Param* Attrib::Desc::getParam ( const char *  key  ) 
static bool Attrib::Desc::getParamString ( const char *  defstr,
const char *  key,
BufferString  
) [static]
BufferString Attrib::Desc::getStoredID ( bool  recursive = false  )  const
Desc* Attrib::Desc::getStoredInput (  )  const
const ValParam* Attrib::Desc::getValParam ( const char *  key  )  const
ValParam* Attrib::Desc::getValParam ( const char *  key  ) 
DescID Attrib::Desc::id (  )  const
DescID Attrib::Desc::inputId ( int  idx  )  const
InputSpec& Attrib::Desc::inputSpec ( int   ) 
const InputSpec& Attrib::Desc::inputSpec ( int   )  const
bool Attrib::Desc::is2D (  )  const [inline]
bool Attrib::Desc::isHidden (  )  const [inline]

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

bool Attrib::Desc::isIdenticalTo ( const Desc ,
bool  cmpoutput = true 
) const
bool Attrib::Desc::isIdentifiedBy ( const char *   )  const
bool Attrib::Desc::isParamEnabled ( const char *  key  )  const
bool Attrib::Desc::isParamRequired ( const char *  key  )  const
SatisfyLevel Attrib::Desc::isSatisfied (  )  const

Checks whether all inputs are satisfied.

bool Attrib::Desc::isSteering (  )  const [inline]
bool Attrib::Desc::isStored (  )  const
Attrib::Desc::mRefCountImpl ( Desc   )  [private]
bool Attrib::Desc::needProvInit (  )  const [inline]
int Attrib::Desc::nrInputs (  )  const
int Attrib::Desc::nrOutputs (  )  const
bool Attrib::Desc::parseDefStr ( const char *   ) 
bool Attrib::Desc::removeInput ( int  idx  ) 
void Attrib::Desc::removeOutputs (  ) 
int Attrib::Desc::selectedOutput (  )  const
void Attrib::Desc::selectOutput ( int   ) 
void Attrib::Desc::set2D ( bool  yn  )  [inline]
void Attrib::Desc::setDescSet ( DescSet  ) 
void Attrib::Desc::setErrMsg ( const char *  str  )  [inline]
void Attrib::Desc::setHidden ( bool  yn  )  [inline]

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

bool Attrib::Desc::setInput ( int  ,
const Desc  
)
bool Attrib::Desc::setInput_ ( int  ,
Desc  
) [protected]
void Attrib::Desc::setNeedProvInit ( bool  yn = true  )  [inline]
void Attrib::Desc::setNrOutputs ( Seis::DataType  ,
int   
)
void Attrib::Desc::setParamEnabled ( const char *  key,
bool  yn = true 
)
void Attrib::Desc::setParamRequired ( const char *  key,
bool  yn = true 
)
void Attrib::Desc::setSteering ( bool  yn  )  [inline]
void Attrib::Desc::setUserRef ( const char *   ) 
static const char* Attrib::Desc::sKeyCrlDipComp (  )  [static]
static const char* Attrib::Desc::sKeyInlDipComp (  )  [static]
void Attrib::Desc::updateDefaultParams (  ) 
void Attrib::Desc::updateParams (  ) 
const char* Attrib::Desc::userRef (  )  const

Member Data Documentation

bool Attrib::Desc::hidden_ [protected]
bool Attrib::Desc::is2d_ [protected]
bool Attrib::Desc::issteering_ [protected]
bool Attrib::Desc::needprovinit_ [protected]
int Attrib::Desc::seloutput_ [protected]