LoRaMesher Library  0.0.5
A LoRa Mesh library for the IoT
RoutingTableService Class Reference

Routing Table Service. More...

#include <RoutingTableService.h>

Static Public Member Functions

static void printRoutingTable ()
 Prints the actual routing table in the log.
 
static NetworkNodegetAllNetworkNodes ()
 Get the All Network Nodes that are inside the routing table. More...
 
static RouteNodefindNode (uint16_t address)
 Find the node that contains the address. More...
 
static bool hasAddressRoutingTable (uint16_t address)
 Returns if address is inside the routing table. More...
 
static uint16_t getNextHop (uint16_t dst)
 Get the Next Hop address. More...
 
static uint8_t getNumberOfHops (uint16_t address)
 Get the Number Of Hops of the address inside the routing table. More...
 
static size_t routingTableSize ()
 Returns the routing table size. More...
 
static void processRoute (RoutePacket *p)
 Process the network packet. More...
 
static void manageTimeoutRoutingTable ()
 Checks all the routing entries for a route timeout and remove the entry.
 

Static Public Attributes

static LM_LinkedList< RouteNode > * routingTableList = new LM_LinkedList<RouteNode>()
 Routing table List.
 

Detailed Description

Routing Table Service.

Member Function Documentation

◆ findNode()

RouteNode * RoutingTableService::findNode ( uint16_t  address)
static

Find the node that contains the address.

Parameters
addressaddress to be found
Returns
RouteNode* pointer to the RouteNode or nullptr

◆ getAllNetworkNodes()

NetworkNode * RoutingTableService::getAllNetworkNodes ( )
static

Get the All Network Nodes that are inside the routing table.

Returns
NetworkNode* All the nodes in a list.

◆ getNextHop()

uint16_t RoutingTableService::getNextHop ( uint16_t  dst)
static

Get the Next Hop address.

Parameters
dstaddress of the next hop
Returns
uint16_t address of the next hop

◆ getNumberOfHops()

uint8_t RoutingTableService::getNumberOfHops ( uint16_t  address)
static

Get the Number Of Hops of the address inside the routing table.

Parameters
addressAddress of the number of hops you want to know
Returns
uint8_t Number of Hops or 0 if address not found in routing table.

◆ hasAddressRoutingTable()

bool RoutingTableService::hasAddressRoutingTable ( uint16_t  address)
static

Returns if address is inside the routing table.

Parameters
addressAddress you want to check if is inside the routing table
Returns
true If the address is inside the routing table
false If the address is not inside the routing table

◆ processRoute()

void RoutingTableService::processRoute ( RoutePacket *  p)
static

Process the network packet.

Parameters
pRoute Packet

◆ routingTableSize()

size_t RoutingTableService::routingTableSize ( )
static

Returns the routing table size.

Returns
size_t

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