Otawa
0.10
|
This class is used for building a lock property, that is, for taking pointer values implementing the elm::Locked class. More...
#include <otawa/prop/Property.h>
Public Member Functions | |
LockedProperty (const AbstractIdentifier *id, T value) | |
Build a new locked property. More... | |
LockedProperty (const AbstractIdentifier &id, T value) | |
Build a new locked property with a static identifier. More... | |
LockedProperty (elm::CString name, T value) | |
Build a new locked property with a named identifier. 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 | ~LockedProperty (void) |
virtual Property * | copy (void) |
This method is called when a property is copied. More... | |
This class is used for building a lock property, that is, for taking pointer values implementing the elm::Locked class.
It provides management of the lock along the life of the property: creation, copy and deletion.
T | Type of the date stored in the property. |
|
inlineprotectedvirtual |
References otawa::GenericProperty< T >::value().
|
inline |
Build a new locked property.
id | Property identifier. |
_value | Lock pointer value. |
References otawa::GenericProperty< T >::value().
|
inline |
Build a new locked property with a static identifier.
id | Property identifier. |
_value | Lock pointer value. |
References otawa::GenericProperty< T >::value().
|
inline |
Build a new locked property with a named identifier.
name | Property identifier name. |
_value | Lock pointer value. |
References otawa::GenericProperty< T >::value().
|
inlineprotectedvirtual |
This method is called when a property is copied.
It may be specialized by Property class children.
Reimplemented from otawa::GenericProperty< 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.