Represent the type of an attribute. More...
#include <attribute.h>
Public Member Functions | |
virtual bool | Check (const AttributeValue &value) const =0 |
virtual std::string | GetValueTypeName (void) const =0 |
virtual bool | HasUnderlyingTypeInformation (void) const =0 |
virtual std::string | GetUnderlyingTypeInformation (void) const =0 |
virtual Ptr< AttributeValue > | Create (void) const =0 |
Represent the type of an attribute.
Each type of attribute has an associated unique AttributeChecker subclass. The type of the subclass can be safely used by users to infer the type of the associated attribute. i.e., we expect binding authors to use the checker associated to an attribute to detect the type of the associated attribute.
Most subclasses of this base class are implemented by the ATTRIBUTE_HELPER_HEADER and ATTRIBUTE_HELPER_CPP macros.
virtual bool ns3::AttributeChecker::Check | ( | const AttributeValue & | value | ) | const [pure virtual] |
value | a pointer to the value to check |
virtual Ptr<AttributeValue> ns3::AttributeChecker::Create | ( | void | ) | const [pure virtual] |
This method is typically used to create a temporary variable prior to calling Attribute::DeserializeFromString.
virtual std::string ns3::AttributeChecker::GetUnderlyingTypeInformation | ( | void | ) | const [pure virtual] |
virtual std::string ns3::AttributeChecker::GetValueTypeName | ( | void | ) | const [pure virtual] |
A typical return value here is FooValue where Foo is the name of the type being wrapped.
virtual bool ns3::AttributeChecker::HasUnderlyingTypeInformation | ( | void | ) | const [pure virtual] |
If this method returns false, the return value of the GetUnderlyingTypeInformation method cannot be relied upon.