22 #ifndef OTAWA_PROC_PARAMFEATURE_H_
23 #define OTAWA_PROC_PARAMFEATURE_H_
25 #include <elm/genstruct/Vector.h>
32 class AbstractParamIdentifier;
33 class AbstractParamProcessor;
T _def
Definition: ParamFeature.h:99
Identifier< T > & operator[](const ActualFeature &feat) const
Definition: ParamFeature.h:91
Implementation of AbstractParamIdentifier for an Identifier.
Definition: ParamFeature.h:84
ParamFeature(cstring id, AbstractParamProcessor &def)
Definition: proc_ParamFeature.cpp:230
static const PropList EMPTY
This is an empty proplist for convenience.
Definition: PropList.h:66
AbstractParamIdentifier(ParamFeature &feature, cstring name)
Build an abstract parametric identifier.
Definition: proc_ParamFeature.cpp:293
const AbstractParamProcessor & processor(void)
Get the default parametric processor.
Definition: ParamFeature.h:41
A parametric identifier allows to instantiate identifier depending on a parametric feature...
Definition: ParamFeature.h:74
const string name(void) const
Get the string name of the identifier.
Definition: AbstractIdentifier.h:43
Identifier< T > & operator[](const ActualFeature *feat) const
Definition: ParamFeature.h:93
Abstract form of a parametric processor.
Definition: ParamProcessor.h:35
void lock(void)
Lock the actual feature (prevent deletion).
Definition: proc_ParamFeature.cpp:204
static Identifier< AbstractParamIdentifier * > PARAM_ID
This identifier is used to hook parametric identifiers associated with a parametric feature...
Definition: ParamFeature.h:61
bool matches(ActualFeature *feat, const PropList &def)
Test if the given feature matches the given properties.
Definition: proc_ParamFeature.cpp:240
const AbstractParamProcessor & proc
Definition: ParamFeature.h:54
const ParamFeature & feat
Definition: ParamFeature.h:53
virtual void process(WorkSpace *ws, const PropList &props=PropList::EMPTY) const
This method is called, when a feature is not available, to provided a default implementation of the f...
Definition: proc_ParamFeature.cpp:179
Represents a unique identifier used by the annotation system.
Definition: AbstractIdentifier.h:32
Processor * def
Definition: Identifier.h:132
ActualFeature(const ParamFeature &feature, const AbstractParamProcessor &def)
Build the actual feature.
Definition: proc_ParamFeature.cpp:164
const AbstractIdentifier *& use(const PropList &list) const
A workspace represents a program, its run-time and all information about WCET computation or any othe...
Definition: WorkSpace.h:67
static AbstractIdentifier ACTUAL_ID
This identifier marks all parametric identifier.
Definition: ParamFeature.h:76
~ActualFeature(void)
Definition: proc_ParamFeature.cpp:170
ParamIdentifier(ParamFeature &feature, cstring name, const T &def)
Definition: ParamFeature.h:88
A parametric feature is a feature that may be instantiated according to some parameters passed in a p...
Definition: ParamFeature.h:59
An actual feature is the result of the instantiation of a parametric feature.
Definition: ParamFeature.h:37
This class represents identifier with a typed associated value.
Definition: Identifier.h:51
virtual void clean(WorkSpace *) const
This method is called each time a feature is invalidated.
Definition: ParamFeature.h:46
void unlock(void)
Unlock the current feature, possibly deleting it.
Definition: proc_ParamFeature.cpp:212
genstruct::Vector< ActualFeature * > feats
Definition: ParamFeature.h:70
const AbstractParamProcessor & proc
Definition: ParamFeature.h:69
const ParamFeature & feature(void) const
Get the instantiated parametric feature.
Definition: ParamFeature.h:40
See Feature.
Definition: AbstractFeature.h:36
This a list of properties.
Definition: PropList.h:63
ActualFeature * instantiate(const PropList &props)
Instantiate the feature.
Definition: proc_ParamFeature.cpp:256
ParamIdentifier(ParamFeature &feature, cstring name)
Definition: ParamFeature.h:86
virtual void check(WorkSpace *) const
Check if the framework really implement the current feature.
Definition: ParamFeature.h:45
virtual AbstractIdentifier * instantiate(ActualFeature &feature) const
Instantiate the identifier.
Definition: ParamFeature.h:96
virtual AbstractIdentifier * instantiate(ActualFeature &feature) const =0
Instantiate the identifier.
int cnt
Definition: ParamFeature.h:55