19 #include "ns3/string.h"
91 std::string name =
"ns3::Ns3NscStack<";
106 tid =
TypeId (name.c_str ());
116 Create<NscStackStringAccessor> (buf),
117 MakeStringChecker ());
132 return std::string (buf);
141 NS_FATAL_ERROR (
"setting " << name <<
" to " << value <<
"failed (retval " << ret <<
")");
148 Ns3NscStack::Ns3NscStack::GetTypeId (
void)
virtual bool HasGetter(void) const
std::string Get(void) const
hold variables of type string
void Set(const std::string &value)
Hold a value for an Attribute.
virtual TypeId GetInstanceTypeId(void) const
static bool LookupByNameFailSafe(std::string name, TypeId *tid)
implement the ns-3 type and attribute system
#define NS_FATAL_ERROR(msg)
fatal error handling
NS_OBJECT_ENSURE_REGISTERED(AntennaModel)
virtual const char * get_name()=0
allow setting and getting the value of an attribute.
NscStackStringAccessor(std::string name)
virtual bool Get(const ObjectBase *object, AttributeValue &val) const
virtual int sysctl_set(const char *name, const char *value)
TypeId AddAttribute(std::string name, std::string help, const AttributeValue &initialValue, Ptr< const AttributeAccessor > accessor, Ptr< const AttributeChecker > checker)
static TypeId GetTypeId(void)
virtual bool HasSetter(void) const
virtual bool Set(ObjectBase *object, const AttributeValue &val) const
virtual int sysctl_getnum(size_t idx, char *name, size_t len)
void Set(std::string name, std::string value)
std::string Get(std::string name) const
a base class which provides memory management and object aggregation
a unique identifier for an interface.
TypeId SetParent(TypeId tid)
virtual int sysctl_get(const char *name, char *value, size_t len)