OpendTect  6.3
attribfactory.h
Go to the documentation of this file.
1 #pragma once
2 
3 /*+
4 ________________________________________________________________________
5 
6  (C) dGB Beheer B.V.; (LICENSE) http://opendtect.org/OpendTect_license.txt
7  Author: Kristofer Tingdahl
8  Date: 07-10-1999
9 ________________________________________________________________________
10 
11 -*/
12 
13 #include "attributeenginemod.h"
14 #include "sets.h"
15 
16 namespace Attrib
17 {
18 
19 class Desc;
20 class Provider;
21 
22 typedef Provider* (*ProviderCreater)(Desc&);
23 
28 mExpClass(AttributeEngine) ProviderFactory
29 {
30 public:
31  ProviderFactory();
32  ~ProviderFactory();
33 
34  /*Interface from attribs' initClass() */
35  void addDesc( Desc*, ProviderCreater );
36 
37  int size() const { return descs_.size();}
38  const Desc& getDesc( int idx ) const { return *descs_[idx]; }
39  const Desc* getDesc(const char*) const;
40 
41  Provider* create( Desc&, bool skipchecks=false ) const;
42  Desc* createDescCopy( const char* nm ) const;
43  void updateAllDescsDefaults();
44 
45 protected:
46 
47  int indexOf( const char* ) const;
50 
51 };
52 
53 mGlobal(AttributeEngine) extern ProviderFactory& PF();
54 
55 }; //Namespace
#define mExpClass(module)
Definition: commondefs.h:157
int size() const
Definition: attribfactory.h:37
Provider *(* ProviderCreater)(Desc &)
Definition: attribfactory.h:22
#define mGlobal(module)
Definition: commondefs.h:160
ObjectSet< Desc > descs_
Definition: attribfactory.h:48
ObjectSet< T >::size_type indexOf(const ObjectSet< T > &os, const S &val)
Locate object in set.
Definition: objectset.h:173
Set of pointers to objects.
Definition: commontypes.h:28
FixedString Desc()
Definition: keystrs.h:60
FixedString Provider()
Definition: keystrs.h:103
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.
Definition: attribdesc.h:87
const Desc & getDesc(int idx) const
Definition: attribfactory.h:38
static uiHor3DInterpol * create(uiParent *)
ProviderFactory & PF()
Provides the actual output to ...
Definition: attribprovider.h:40
Factory for attribute providers.
Definition: attribfactory.h:28
TypeSet< ProviderCreater > creaters_
Definition: attribfactory.h:49
Semblance Attribute.
Definition: attribdataholder.h:21

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