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

The network layer Route Discovery Table See Zigbee specification r22.1.0, 3.6.3.2. More...

#include "zigbee-nwk-tables.h"

+ Collaboration diagram for ns3::zigbee::RouteDiscoveryTable:

Public Member Functions

 RouteDiscoveryTable ()
 Constructor of route discovery table.
 
bool AddEntry (Ptr< RouteDiscoveryTableEntry > rt)
 Add an entry to the route discovery table, in essence the contents of a RREQ command.
 
void Delete (uint8_t id, Mac16Address src)
 Delete an entry from the route discovery table.
 
void Dispose ()
 Dispose of the table and all its elements.
 
bool LookUpEntry (uint8_t id, Mac16Address src, Ptr< RouteDiscoveryTableEntry > &entryFound)
 Look up for a route discovery table entry, the seareched entry must match the id and the src address of the initiator.
 
void Print (Ptr< OutputStreamWrapper > stream)
 Print the contents of the route discovery table.
 
void Purge ()
 Purge old entries from the route discovery table.
 

Private Attributes

uint32_t m_maxTableSize
 The maximum size of the route discovery table.
 
std::deque< Ptr< RouteDiscoveryTableEntry > > m_routeDscTable
 The route discovery table object.
 

Detailed Description

The network layer Route Discovery Table See Zigbee specification r22.1.0, 3.6.3.2.

Definition at line 1028 of file zigbee-nwk-tables.h.

Constructor & Destructor Documentation

◆ RouteDiscoveryTable()

ns3::zigbee::RouteDiscoveryTable::RouteDiscoveryTable ( )

Constructor of route discovery table.

Definition at line 586 of file zigbee-nwk-tables.cc.

References m_maxTableSize.

Member Function Documentation

◆ AddEntry()

bool ns3::zigbee::RouteDiscoveryTable::AddEntry ( Ptr< RouteDiscoveryTableEntry > rt)

Add an entry to the route discovery table, in essence the contents of a RREQ command.

Parameters
rtThe route discovery table entry.
Returns
True if the entry was added successfully

Definition at line 592 of file zigbee-nwk-tables.cc.

References m_maxTableSize, m_routeDscTable, and Purge().

Referenced by ns3::zigbee::ZigbeeNwk::FindNextHop(), and ns3::zigbee::ZigbeeNwk::ProcessManyToOneRoute().

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

◆ Delete()

void ns3::zigbee::RouteDiscoveryTable::Delete ( uint8_t id,
Mac16Address src )

Delete an entry from the route discovery table.

Parameters
idThe RREQ id of the entry to delete.
srcThe src address of the initiator of the entry to delete.

Definition at line 634 of file zigbee-nwk-tables.cc.

References m_routeDscTable.

Referenced by ns3::zigbee::ZigbeeNwk::ReceiveRREP().

+ Here is the caller graph for this function:

◆ Dispose()

void ns3::zigbee::RouteDiscoveryTable::Dispose ( )

Dispose of the table and all its elements.

Definition at line 667 of file zigbee-nwk-tables.cc.

References m_routeDscTable.

Referenced by ns3::zigbee::ZigbeeNwk::DoDispose().

+ Here is the caller graph for this function:

◆ LookUpEntry()

bool ns3::zigbee::RouteDiscoveryTable::LookUpEntry ( uint8_t id,
Mac16Address src,
Ptr< RouteDiscoveryTableEntry > & entryFound )

Look up for a route discovery table entry, the seareched entry must match the id and the src address of the initiator.

Parameters
idThe RREQ id (RREQ command sequence number)
srcThe 16 bit address of the initiator device.
entryFoundThe returned entry if found
Returns
True if element found

Definition at line 608 of file zigbee-nwk-tables.cc.

References m_routeDscTable, NS_LOG_FUNCTION, and Purge().

Referenced by ns3::zigbee::ZigbeeNwk::FindNextHop(), ns3::zigbee::ZigbeeNwk::ProcessManyToOneRoute(), and ns3::zigbee::ZigbeeNwk::ReceiveRREP().

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

◆ Print()

void ns3::zigbee::RouteDiscoveryTable::Print ( Ptr< OutputStreamWrapper > stream)

Print the contents of the route discovery table.

Parameters
streamThe stream object used to print the table.

Definition at line 642 of file zigbee-nwk-tables.cc.

References m_routeDscTable, and Purge().

Referenced by ns3::zigbee::ZigbeeNwk::PrintRouteDiscoveryTable().

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

◆ Purge()

void ns3::zigbee::RouteDiscoveryTable::Purge ( )

Purge old entries from the route discovery table.

Definition at line 626 of file zigbee-nwk-tables.cc.

References m_routeDscTable, and ns3::Simulator::Now().

Referenced by AddEntry(), LookUpEntry(), and Print().

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

Member Data Documentation

◆ m_maxTableSize

uint32_t ns3::zigbee::RouteDiscoveryTable::m_maxTableSize
private

The maximum size of the route discovery table.

Definition at line 1081 of file zigbee-nwk-tables.h.

Referenced by RouteDiscoveryTable(), and AddEntry().

◆ m_routeDscTable

std::deque<Ptr<RouteDiscoveryTableEntry> > ns3::zigbee::RouteDiscoveryTable::m_routeDscTable
private

The route discovery table object.

Definition at line 1082 of file zigbee-nwk-tables.h.

Referenced by AddEntry(), Delete(), Dispose(), LookUpEntry(), Print(), and Purge().


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