akmhoque | 298385a | 2014-02-13 14:13:09 -0600 | [diff] [blame] | 1 | #ifndef NLSR_NPT_HPP |
| 2 | #define NLSR_NPT_HPP |
| 3 | |
| 4 | #include <list> |
| 5 | #include "nlsr_npte.hpp" |
| 6 | #include "nlsr_rte.hpp" |
| 7 | |
| 8 | using namespace std; |
| 9 | |
akmhoque | 1a48109 | 2014-02-19 16:34:22 -0600 | [diff] [blame^] | 10 | class Nlsr; |
akmhoque | 298385a | 2014-02-13 14:13:09 -0600 | [diff] [blame] | 11 | |
| 12 | class Npt |
| 13 | { |
| 14 | public: |
| 15 | Npt() |
| 16 | { |
| 17 | } |
akmhoque | 1a48109 | 2014-02-19 16:34:22 -0600 | [diff] [blame^] | 18 | void addNpte(string name, string destRouter, Nlsr& pnlsr); |
| 19 | void removeNpte(string name, string destRouter, Nlsr& pnlsr); |
| 20 | void updateNptWithNewRoute(Nlsr& pnlsr); |
akmhoque | 298385a | 2014-02-13 14:13:09 -0600 | [diff] [blame] | 21 | void printNpt(); |
| 22 | private: |
akmhoque | 1a48109 | 2014-02-19 16:34:22 -0600 | [diff] [blame^] | 23 | void addNpte(string name, RoutingTableEntry& rte, Nlsr& pnlsr); |
| 24 | void removeNpte(string name, RoutingTableEntry& rte, Nlsr& pnlsr); |
akmhoque | 298385a | 2014-02-13 14:13:09 -0600 | [diff] [blame] | 25 | private: |
| 26 | std::list<Npte> npteList; |
| 27 | }; |
| 28 | |
| 29 | #endif |