61 const auto str =
dynamic_cast<const StringValue*
>(&value);
68 bool ok = v->DeserializeFromString(str->Get(),
this);
160 return "EmptyAttribute";
ns3::AttributeValue, ns3::AttributeAccessor and ns3::AttributeChecker declarations.
allow setting and getting the value of an attribute.
virtual ~AttributeAccessor()
Represent the type of an attribute.
virtual ~AttributeChecker()
virtual bool Check(const AttributeValue &value) const =0
Ptr< AttributeValue > CreateValidValue(const AttributeValue &value) const
Create a valid value from the argument value, or reinterpret the argument as a string.
virtual Ptr< AttributeValue > Create() const =0
Hold a value for an Attribute.
virtual ~AttributeValue()
bool Get(const ObjectBase *object, AttributeValue &attribute) const override
bool Set(ObjectBase *object, const AttributeValue &value) const override
~EmptyAttributeAccessor() override
bool HasSetter() const override
bool HasGetter() const override
std::string GetValueTypeName() const override
bool Check(const AttributeValue &value) const override
Ptr< AttributeValue > Create() const override
bool Copy(const AttributeValue &source, AttributeValue &destination) const override
Copy the source to the destination.
bool HasUnderlyingTypeInformation() const override
~EmptyAttributeChecker() override
std::string GetUnderlyingTypeInformation() const override
A class for an empty attribute value.
std::string SerializeToString(Ptr< const AttributeChecker > checker) const override
EmptyAttributeValue()
Default constructor.
Ptr< AttributeValue > Copy() const override
bool DeserializeFromString(std::string value, Ptr< const AttributeChecker > checker) override
Anchor the ns-3 type and attribute system.
Smart pointer class similar to boost::intrusive_ptr.
Hold variables of type string.
NS_FATAL_x macro definitions.
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name.
#define NS_LOG_FUNCTION(parameters)
If log level LOG_FUNCTION is enabled, this macro will output all input parameters separated by ",...
Ptr< T > Create(Ts &&... args)
Create class instances by constructors with varying numbers of arguments and return them by Ptr.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
ns3::StringValue attribute value declarations.