Otawa
0.10
|
A deletable property is a genericproperty whose value will be deleted when the property is destroyed. More...
#include <otawa/prop/DeletableProperty.h>
Public Member Functions | |
DeletableProperty (const AbstractIdentifier *id, T value) | |
DeletableProperty (const AbstractIdentifier &id, T value) | |
DeletableProperty (elm::CString name, T value) | |
Build a new deletable property. More... | |
virtual Property * | copy (void) |
This method is called when a property is copied. More... | |
const T & | value (void) const |
Get the value of the property. More... | |
T & | value (void) |
Get the value of the property. More... | |
const AbstractIdentifier * | id (void) const |
Get the identifier code of the property. More... | |
Property * | next (void) const |
Get the next property. More... | |
template<class T > | |
const T & | get (void) const |
template<class T > | |
void | set (const T &value) |
virtual void | print (elm::io::Output &out) const |
Print the given property, that is, the identifier and its value if any. More... | |
Static Public Member Functions | |
static GenericProperty< T > * | make (const AbstractIdentifier *id, const T &value) |
Build a new generic property with the given data. More... | |
static const AbstractIdentifier * | getID (elm::CString name) |
Allocate a new identifier matching the given name. More... | |
Protected Member Functions | |
virtual | ~DeletableProperty (void) |
Delete also its value. More... | |
A deletable property is a genericproperty whose value will be deleted when the property is destroyed.
T | Type of the date stored in the property. |
|
protectedvirtual |
Delete also its value.
References otawa::GenericProperty< T >::value().
|
inline |
|
inline |
|
inline |
Build a new deletable property.
name | Annotation name (matching identifier is automatically retrieved). |
_value | Annotation value. |
|
inlinevirtualinherited |
This method is called when a property is copied.
It may be specialized by Property class children.
Reimplemented from otawa::Property.
Reimplemented in otawa::LockedProperty< T >.
References otawa::Property::id(), and otawa::GenericProperty< T >::value().
|
inlineinherited |
|
staticinherited |
Allocate a new identifier matching the given name.
Note that, if an identifier exists with the same name, its code will be returned ensuring consistency between name and code for identifiers.
name | Name of the identifier. |
References otawa::display::find().
|
inlineinherited |
Get the identifier code of the property.
References otawa::Property::_id.
Referenced by otawa::GenericProperty< T >::copy(), otawa::LockedProperty< T >::copy(), otawa::PropList::Iter::operator!=(), otawa::PropList::Iter::operator==(), and otawa::PropList::setProp().
|
inlinestaticinherited |
Build a new generic property with the given data.
Defining the constructor as is, allows replacing the default building behaviour by specialized ones.
id | Identifier of the property. |
value | Value of the property. |
References otawa::GenericProperty< T >::GenericProperty().
Referenced by otawa::Identifier< otawa::arm::Info * >::copy(), and otawa::Identifier< T >::ref().
|
inlineinherited |
Get the next property.
References otawa::Property::_next.
Referenced by otawa::PropList::addProps(), otawa::PropList::clearProps(), otawa::PropList::extractProp(), otawa::PropList::getProp(), otawa::PropList::Iter::next(), otawa::PropList::removeAllProp(), otawa::PropList::removeProp(), and otawa::PropList::setProp().
|
virtualinherited |
Print the given property, that is, the identifier and its value if any.
out | Output to use. |
Referenced by otawa::operator<<().
|
inlineinherited |
|
inlineinherited |
Get the value of the property.
References otawa::GenericProperty< T >::_value.
Referenced by otawa::GenericProperty< T >::copy(), otawa::LockedProperty< T >::copy(), otawa::LockedProperty< T >::LockedProperty(), otawa::Identifier< T >::ref(), otawa::DeletableProperty< T >::~DeletableProperty(), and otawa::LockedProperty< T >::~LockedProperty().
|
inlineinherited |
Get the value of the property.
References otawa::GenericProperty< T >::_value.