A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
ns3::BuildingListPriv Class Reference

private implementation detail of the BuildingList API. More...

#include "introspected-doxygen.h"

+ Inheritance diagram for ns3::BuildingListPriv:
+ Collaboration diagram for ns3::BuildingListPriv:

Public Member Functions

 BuildingListPriv ()
 
 ~BuildingListPriv () override
 
uint32_t Add (Ptr< Building > building)
 Add a Building to the list.
 
BuildingList::Iterator Begin () const
 Returns an iterator to the start of the list.
 
BuildingList::Iterator End () const
 Returns an iterator to the end of the list.
 
Ptr< BuildingGetBuilding (uint32_t n)
 Gets the n-th Building in the container.
 
uint32_t GetNBuildings ()
 Gets the number of Building in the container.
 
- Public Member Functions inherited from ns3::Object
 Object ()
 Constructor.
 
 ~Object () override
 Destructor.
 
void AggregateObject (Ptr< Object > other)
 Aggregate two Objects together.
 
void Dispose ()
 Dispose of this Object.
 
AggregateIterator GetAggregateIterator () const
 Get an iterator to the Objects aggregated to this one.
 
TypeId GetInstanceTypeId () const override
 Get the most derived TypeId for this Object.
 
template<typename T >
Ptr< T > GetObject () const
 Get a pointer to the requested aggregated Object.
 
template<>
Ptr< ObjectGetObject () const
 Specialization of () for objects of type ns3::Object.
 
template<typename T >
Ptr< T > GetObject (TypeId tid) const
 Get a pointer to the requested aggregated Object by TypeId.
 
template<>
Ptr< ObjectGetObject (TypeId tid) const
 Specialization of (TypeId tid) for objects of type ns3::Object.
 
void Initialize ()
 Invoke DoInitialize on all Objects aggregated to this one.
 
bool IsInitialized () const
 Check if the object has been initialized.
 
void UnidirectionalAggregateObject (Ptr< Object > other)
 Aggregate an Object to another Object.
 
- Public Member Functions inherited from ns3::SimpleRefCount< Object, ObjectBase, ObjectDeleter >
 SimpleRefCount ()
 Default constructor.
 
 SimpleRefCount (const SimpleRefCount &o)
 Copy constructor.
 
uint32_t GetReferenceCount () const
 Get the reference count of the object.
 
SimpleRefCountoperator= (const SimpleRefCount &o)
 Assignment operator.
 
void Ref () const
 Increment the reference count.
 
void Unref () const
 Decrement the reference count.
 
- Public Member Functions inherited from ns3::ObjectBase
virtual ~ObjectBase ()
 Virtual destructor.
 
void GetAttribute (std::string name, AttributeValue &value) const
 Get the value of an attribute, raising fatal errors if unsuccessful.
 
bool GetAttributeFailSafe (std::string name, AttributeValue &value) const
 Get the value of an attribute without raising errors.
 
virtual TypeId GetInstanceTypeId () const =0
 Get the most derived TypeId for this Object.
 
void SetAttribute (std::string name, const AttributeValue &value)
 Set a single attribute, raising fatal errors if unsuccessful.
 
bool SetAttributeFailSafe (std::string name, const AttributeValue &value)
 Set a single attribute without raising errors.
 
bool TraceConnect (std::string name, std::string context, const CallbackBase &cb)
 Connect a TraceSource to a Callback with a context.
 
bool TraceConnectWithoutContext (std::string name, const CallbackBase &cb)
 Connect a TraceSource to a Callback without a context.
 
bool TraceDisconnect (std::string name, std::string context, const CallbackBase &cb)
 Disconnect from a TraceSource a Callback previously connected with a context.
 
bool TraceDisconnectWithoutContext (std::string name, const CallbackBase &cb)
 Disconnect from a TraceSource a Callback previously connected without a context.
 

Static Public Member Functions

static Ptr< BuildingListPrivGet ()
 Get the Singleton instance of BuildingListPriv (or create one)
 
static TypeId GetTypeId ()
 Get the type ID.
 
- Static Public Member Functions inherited from ns3::Object
static TypeId GetTypeId ()
 Register this type.
 
- Static Public Member Functions inherited from ns3::ObjectBase
static TypeId GetTypeId ()
 Get the type ID.
 

Private Member Functions

void DoDispose () override
 Destructor implementation.
 

Static Private Member Functions

static void Delete ()
 Dispose the Singleton instance of BuildingListPriv.
 
static Ptr< BuildingListPriv > * DoGet ()
 Get the Singleton instance of BuildingListPriv (or create one)
 

Private Attributes

std::vector< Ptr< Building > > m_buildings
 Container of Building.
 

Additional Inherited Members

- Protected Member Functions inherited from ns3::Object
 Object (const Object &o)
 Copy an Object.
 
virtual void DoDispose ()
 Destructor implementation.
 
virtual void DoInitialize ()
 Initialize() implementation.
 
virtual void NotifyNewAggregate ()
 Notify all Objects aggregated to this one of a new Object being aggregated.
 
- Protected Member Functions inherited from ns3::ObjectBase
void ConstructSelf (const AttributeConstructionList &attributes)
 Complete construction of ObjectBase; invoked by derived classes.
 
virtual void NotifyConstructionCompleted ()
 Notifier called once the ObjectBase is fully constructed.
 

Detailed Description

private implementation detail of the BuildingList API.

Introspection did not find any typical Config paths.


Attributes

No TraceSources are defined for this type.
Size of this type is 80 bytes (on a 64-bit architecture).

Definition at line 39 of file building-list.cc.

Constructor & Destructor Documentation

◆ BuildingListPriv()

ns3::BuildingListPriv::BuildingListPriv ( )

Definition at line 148 of file building-list.cc.

References NS_LOG_FUNCTION_NOARGS.

◆ ~BuildingListPriv()

ns3::BuildingListPriv::~BuildingListPriv ( )
override

Definition at line 153 of file building-list.cc.

Member Function Documentation

◆ Add()

uint32_t ns3::BuildingListPriv::Add ( Ptr< Building building)

Add a Building to the list.

Parameters
buildingbuilding to add
Returns
index of building in list.

Definition at line 172 of file building-list.cc.

References ns3::Object::Initialize(), m_buildings, and ns3::Simulator::ScheduleWithContext().

+ Here is the call graph for this function:

◆ Begin()

BuildingList::Iterator ns3::BuildingListPriv::Begin ( ) const

Returns an iterator to the start of the list.

Returns
iterator to the begin of the container.

Definition at line 181 of file building-list.cc.

References m_buildings.

◆ Delete()

void ns3::BuildingListPriv::Delete ( )
staticprivate

Dispose the Singleton instance of BuildingListPriv.

Note
: this function is automatically called at the simulation end.

Definition at line 141 of file building-list.cc.

References DoGet(), Get(), NS_LOG_FUNCTION_NOARGS, and ns3::Config::UnregisterRootNamespaceObject().

Referenced by DoGet().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ DoDispose()

void ns3::BuildingListPriv::DoDispose ( )
overrideprivatevirtual

Destructor implementation.

This method is called by Dispose() or by the Object's destructor, whichever comes first.

Subclasses are expected to implement their real destruction code in an overridden version of this method and chain up to their parent's implementation once they are done. i.e, for simplicity, the destructor of every subclass should be empty and its content should be moved to the associated DoDispose() method.

It is safe to call GetObject() from within this method.

Reimplemented from ns3::Object.

Definition at line 158 of file building-list.cc.

References ns3::Object::DoDispose(), m_buildings, and NS_LOG_FUNCTION_NOARGS.

+ Here is the call graph for this function:

◆ DoGet()

Ptr< BuildingListPriv > * ns3::BuildingListPriv::DoGet ( )
staticprivate

Get the Singleton instance of BuildingListPriv (or create one)

Returns
the BuildingListPriv instance

Definition at line 128 of file building-list.cc.

References Delete(), ns3::Config::RegisterRootNamespaceObject(), and ns3::Simulator::ScheduleDestroy().

Referenced by Delete(), and Get().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ End()

BuildingList::Iterator ns3::BuildingListPriv::End ( ) const

Returns an iterator to the end of the list.

Returns
iterator to the end of the container.

Definition at line 187 of file building-list.cc.

References m_buildings.

◆ Get()

Ptr< BuildingListPriv > ns3::BuildingListPriv::Get ( )
static

Get the Singleton instance of BuildingListPriv (or create one)

Returns
the BuildingListPriv instance

Definition at line 122 of file building-list.cc.

References DoGet().

Referenced by ns3::BuildingList::Add(), ns3::BuildingList::Begin(), Delete(), ns3::BuildingList::End(), ns3::BuildingList::GetBuilding(), and ns3::BuildingList::GetNBuildings().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ GetBuilding()

Ptr< Building > ns3::BuildingListPriv::GetBuilding ( uint32_t  n)

Gets the n-th Building in the container.

Parameters
nBuilding position
Returns
a pointer to the Building

Definition at line 199 of file building-list.cc.

References m_buildings, and NS_ASSERT_MSG.

◆ GetNBuildings()

uint32_t ns3::BuildingListPriv::GetNBuildings ( )

Gets the number of Building in the container.

Returns
the container size

Definition at line 193 of file building-list.cc.

References m_buildings.

◆ GetTypeId()

TypeId ns3::BuildingListPriv::GetTypeId ( )
static

Get the type ID.

Returns
The object TypeId.

Definition at line 107 of file building-list.cc.

References m_buildings, ns3::MakeObjectVectorAccessor(), and ns3::TypeId::SetParent().

+ Here is the call graph for this function:

Member Data Documentation

◆ m_buildings

std::vector<Ptr<Building> > ns3::BuildingListPriv::m_buildings
private

Container of Building.

Definition at line 101 of file building-list.cc.

Referenced by Add(), Begin(), DoDispose(), End(), GetBuilding(), GetNBuildings(), and GetTypeId().


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