A Discrete-Event Network Simulator
API
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
ns3::AccessorHelper< T, U > Class Template Referenceabstract

#include <attribute-accessor-helper.h>

+ Inheritance diagram for ns3::AccessorHelper< T, U >:
+ Collaboration diagram for ns3::AccessorHelper< T, U >:

Public Member Functions

 AccessorHelper ()
 
virtual bool Get (const ObjectBase *object, AttributeValue &val) const
 
virtual bool Set (ObjectBase *object, const AttributeValue &val) const
 
- Public Member Functions inherited from ns3::AttributeAccessor
 AttributeAccessor ()
 
virtual ~AttributeAccessor ()
 
virtual bool HasGetter (void) const =0
 
virtual bool HasSetter (void) const =0
 
- Public Member Functions inherited from ns3::SimpleRefCount< AttributeAccessor >
 SimpleRefCount ()
 Constructor. More...
 
 SimpleRefCount (const SimpleRefCount &o)
 Copy constructor. More...
 
uint32_t GetReferenceCount (void) const
 Get the reference count of the object. More...
 
SimpleRefCountoperator= (const SimpleRefCount &o)
 Assignment. More...
 
void Ref (void) const
 Increment the reference count. More...
 
void Unref (void) const
 Decrement the reference count. More...
 

Private Member Functions

virtual bool DoGet (const T *object, U *v) const =0
 
virtual bool DoSet (T *object, const U *v) const =0
 

Additional Inherited Members

- Static Public Member Functions inherited from ns3::SimpleRefCount< AttributeAccessor >
static void Cleanup (void)
 Noop. More...
 

Detailed Description

template<typename T, typename U>
class ns3::AccessorHelper< T, U >

Definition at line 58 of file attribute-accessor-helper.h.

Constructor & Destructor Documentation

template<typename T , typename U >
ns3::AccessorHelper< T, U >::AccessorHelper ( )
inline

Definition at line 61 of file attribute-accessor-helper.h.

Member Function Documentation

template<typename T , typename U >
virtual bool ns3::AccessorHelper< T, U >::DoGet ( const T *  object,
U *  v 
) const
privatepure virtual

Referenced by ns3::AccessorHelper< T, U >::Get().

+ Here is the caller graph for this function:

template<typename T , typename U >
virtual bool ns3::AccessorHelper< T, U >::DoSet ( T *  object,
const U *  v 
) const
privatepure virtual

Referenced by ns3::AccessorHelper< T, U >::Set().

+ Here is the caller graph for this function:

template<typename T , typename U >
virtual bool ns3::AccessorHelper< T, U >::Get ( const ObjectBase object,
AttributeValue attribute 
) const
inlinevirtual
Parameters
objectthe object instance to get the value from
attributea pointer to where the value should be set.
Returns
true if the value could be read successfully, and stored in the input value, false otherwise.

This method expects that the caller has checked that the input value is valid with AttributeChecker::Check.

Implements ns3::AttributeAccessor.

Definition at line 77 of file attribute-accessor-helper.h.

References ns3::AccessorHelper< T, U >::DoGet().

+ Here is the call graph for this function:

template<typename T , typename U >
virtual bool ns3::AccessorHelper< T, U >::Set ( ObjectBase object,
const AttributeValue value 
) const
inlinevirtual
Parameters
objectthe object instance to set the value in
valuethe value to set
Returns
true if the value could be set successfully, false otherwise.

This method expects that the caller has checked that the input value is valid with AttributeChecker::Check.

Implements ns3::AttributeAccessor.

Definition at line 63 of file attribute-accessor-helper.h.

References ns3::AccessorHelper< T, U >::DoSet().

Referenced by ns3::DoMakeAccessorHelperOne(), and ns3::DoMakeAccessorHelperTwo().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:


The documentation for this class was generated from the following file: