blob: 8e6a98c79beff3586108cfdcde0c782234b04315 [file] [log] [blame]
akmhoqueba094742014-02-28 11:47:21 -06001#ifndef NLSR_NPT_HPP
2#define NLSR_NPT_HPP
3
4#include <list>
5#include "nlsr_npte.hpp"
6#include "nlsr_rte.hpp"
7
8namespace nlsr
9{
10
akmhoque5a44dd42014-03-12 18:11:32 -050011 using namespace std;
akmhoqueba094742014-02-28 11:47:21 -060012
akmhoque5a44dd42014-03-12 18:11:32 -050013 class Nlsr;
akmhoqueba094742014-02-28 11:47:21 -060014
akmhoque5a44dd42014-03-12 18:11:32 -050015 class Npt
16 {
17 public:
18 Npt()
akmhoqueba094742014-02-28 11:47:21 -060019 {
akmhoque5a44dd42014-03-12 18:11:32 -050020 }
21 void addNpteByDestName(string name, string destRouter, Nlsr& pnlsr);
22 void removeNpte(string name, string destRouter, Nlsr& pnlsr);
23 void updateNptWithNewRoute(Nlsr& pnlsr);
24 void printNpt();
25 private:
26 void addNpte(string name, RoutingTableEntry& rte, Nlsr& pnlsr);
27 void removeNpte(string name, RoutingTableEntry& rte, Nlsr& pnlsr);
28 private:
29 std::list<Npte> npteList;
30 };
akmhoqueba094742014-02-28 11:47:21 -060031
32}//namespace nlsr
33
34#endif