ns3::LoraNetworkServer Class Reference

The LoraNetworkServer is an application standing on top of a node equipped with links that connect it with the gateways. More...

#include "lora-network-server.h"

+ Inheritance diagram for ns3::LoraNetworkServer:
+ Collaboration diagram for ns3::LoraNetworkServer:

Public Member Functions

 LoraNetworkServer ()
 
virtual ~LoraNetworkServer ()
 
void AddComponent (Ptr< LoraNetworkControllerComponent > component)
 A NetworkControllerComponent to this LoraNetworkServer instance. More...
 
void AddGateway (Ptr< Node > gateway, Ptr< NetDevice > netDevice)
 Add this gateway to the list of gateways connected to this NS. More...
 
void AddNode (Ptr< Node > node)
 Inform the LoraNetworkServer that this node is connected to the network. More...
 
void AddNodes (NodeContainer nodes)
 Inform the LoraNetworkServer that these nodes are connected to the network. More...
 
Ptr< LoraNetworkStatusGetNetworkStatus (void)
 
bool Receive (Ptr< NetDevice > device, Ptr< const Packet > packet, uint16_t protocol, const Address &address)
 Receive a packet from a gateway. More...
 
void StartApplication (void)
 Start the NS application. More...
 
void StopApplication (void)
 Stop the NS application. More...
 

Static Public Member Functions

static TypeId GetTypeId (void)
 

Protected Attributes

Ptr< LoraNetworkControllerm_controller
 
TracedCallback< Ptr< const Packet > > m_receivedPacket
 
Ptr< LoraNetworkSchedulerm_scheduler
 
Ptr< LoraNetworkStatusm_status
 

Detailed Description

The LoraNetworkServer is an application standing on top of a node equipped with links that connect it with the gateways.

This version of the LoraNetworkServer attempts to closely mimic an actual Network Server, by providing as much functionality as possible.

Definition at line 51 of file lora-network-server.h.

Constructor & Destructor Documentation

◆ LoraNetworkServer()

ns3::LoraNetworkServer::LoraNetworkServer ( )

Definition at line 58 of file lora-network-server.cc.

◆ ~LoraNetworkServer()

ns3::LoraNetworkServer::~LoraNetworkServer ( )
virtual

Definition at line 66 of file lora-network-server.cc.

Member Function Documentation

◆ AddComponent()

void ns3::LoraNetworkServer::AddComponent ( Ptr< LoraNetworkControllerComponent component)

A NetworkControllerComponent to this LoraNetworkServer instance.

Definition at line 177 of file lora-network-server.cc.

References m_controller.

◆ AddGateway()

void ns3::LoraNetworkServer::AddGateway ( Ptr< Node >  gateway,
Ptr< NetDevice >  netDevice 
)

Add this gateway to the list of gateways connected to this NS.

Each GW is identified by its Address in the NS-GWs network.

Definition at line 84 of file lora-network-server.cc.

References m_status.

◆ AddNode()

void ns3::LoraNetworkServer::AddNode ( Ptr< Node >  node)

Inform the LoraNetworkServer that this node is connected to the network.

This method will create a DeviceStatus object for the new node (if it doesn't already exist).

Definition at line 129 of file lora-network-server.cc.

References m_status.

Referenced by AddNodes().

+ Here is the caller graph for this function:

◆ AddNodes()

void ns3::LoraNetworkServer::AddNodes ( NodeContainer  nodes)

Inform the LoraNetworkServer that these nodes are connected to the network.

This method will create a DeviceStatus object for each new node, and add it to the list.

Definition at line 116 of file lora-network-server.cc.

References AddNode().

+ Here is the call graph for this function:

◆ GetNetworkStatus()

Ptr< LoraNetworkStatus > ns3::LoraNetworkServer::GetNetworkStatus ( void  )

Definition at line 185 of file lora-network-server.cc.

References m_status.

◆ GetTypeId()

TypeId ns3::LoraNetworkServer::GetTypeId ( void  )
static

Definition at line 44 of file lora-network-server.cc.

References m_receivedPacket.

◆ Receive()

bool ns3::LoraNetworkServer::Receive ( Ptr< NetDevice >  device,
Ptr< const Packet >  packet,
uint16_t  protocol,
const Address &  address 
)

Receive a packet from a gateway.

Parameters
packetthe received packet

Definition at line 154 of file lora-network-server.cc.

References m_controller, m_receivedPacket, m_scheduler, and m_status.

Referenced by ns3::LoraNetworkServerHelper::InstallPriv().

+ Here is the caller graph for this function:

◆ StartApplication()

void ns3::LoraNetworkServer::StartApplication ( void  )

Start the NS application.

Definition at line 72 of file lora-network-server.cc.

◆ StopApplication()

void ns3::LoraNetworkServer::StopApplication ( void  )

Stop the NS application.

Definition at line 78 of file lora-network-server.cc.

Member Data Documentation

◆ m_controller

Ptr<LoraNetworkController> ns3::LoraNetworkServer::m_controller
protected

Definition at line 108 of file lora-network-server.h.

Referenced by AddComponent(), and Receive().

◆ m_receivedPacket

TracedCallback<Ptr<const Packet> > ns3::LoraNetworkServer::m_receivedPacket
protected

Definition at line 111 of file lora-network-server.h.

Referenced by GetTypeId(), and Receive().

◆ m_scheduler

Ptr<LoraNetworkScheduler> ns3::LoraNetworkServer::m_scheduler
protected

Definition at line 109 of file lora-network-server.h.

Referenced by Receive().

◆ m_status

Ptr<LoraNetworkStatus> ns3::LoraNetworkServer::m_status
protected

Definition at line 107 of file lora-network-server.h.

Referenced by AddGateway(), AddNode(), GetNetworkStatus(), and Receive().


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