Maps names to lists of next hops, and exports this information to NFD. More...
|Fib (ndn::Face &face, ndn::Scheduler &scheduler, AdjacencyList &adjacencyList, ConfParameter &conf, ndn::security::KeyChain &keyChain)|
|Remove all entries from the FIB. More...|
|void||registerPrefix (const ndn::Name &namePrefix, const ndn::FaceUri &faceUri, uint64_t faceCost, const ndn::time::milliseconds &timeout, uint64_t flags, uint8_t times)|
|Inform NFD of a next-hop. More...|
|void||remove (const ndn::Name &name)|
|Completely remove a name prefix from the FIB. More...|
|void||setEntryRefreshTime (int32_t fert)|
|void||setStrategy (const ndn::Name &name, const std::string &strategy, uint32_t count)|
|void||update (const ndn::Name &name, const NexthopList &allHops)|
|Set the nexthop list of a name. More...|
|ndn::util::Signal< Fib, const ndn::Name & >||onPrefixRegistrationSuccess|
|static const std::string||BEST_ROUTE_V2_STRATEGY|
|static const std::string||MULTICAST_STRATEGY|
Maps names to lists of next hops, and exports this information to NFD.
The FIB (Forwarding Information Base) is the "authoritative" source of how to route Interests on this router to other nodes running NLSR. In essence, the FIB is a map that takes name prefixes to a list of next-hops out of this router. This class also contains methods to inform NFD about these relationships. The FIB has its entries populated by the NamePrefixTable
Remove all entries from the FIB.
This method is called before terminating NLSR to minimize the time NFD spends routing on now-invalid information. This is not strictly necessary, because eventually those prefix registrations will expire, but cleaning up after ourselves improves performance.
|void nlsr::Fib::registerPrefix||(||const ndn::Name &||namePrefix,|
|const ndn::FaceUri &||faceUri,|
|const ndn::time::milliseconds &||timeout,|
Inform NFD of a next-hop.
This method informs NFD of a next-hop for some name prefix. This method actually submits the information to NFD's RIB, which then aggregates its own best hops and updates NFD's (the actual) FIB. Typically, NLSR's FIB and NFD's FIB will be almost the same. However, this is not necessarily the case and there may be cases when other sources of information provide better next-hops to NFD that NLSR doesn't know about. For example, an operator could set up a direct link to a node that isn't running NLSR.
|namePrefix||The name prefix to register a next-hop for|
|faceUri||The faceUri of the adjacent that this prefix can be reached through|
|faceCost||The cost to reach namePrefix through faceUri|
|timeout||How long this registration should last|
|flags||Route inheritance flags (CAPTURE, CHILD_INHERIT)|
|times||How many times we have failed to register this prefix since the last success.|
|void nlsr::Fib::remove||(||const ndn::Name &||name||)|
Completely remove a name prefix from the FIB.
If a name prefix is found to no longer be reachable from this router, it will be removed from the FIB and all of its next-hops will be unregistered from NFD.
|void nlsr::Fib::setStrategy||(||const ndn::Name &||name,|
|const std::string &||strategy,|
|void nlsr::Fib::update||(||const ndn::Name &||name,|
|const NexthopList &||allHops|
Set the nexthop list of a name.
This method is the entry for others to add next-hop information to the FIB. Formally put, this method registers in NFD all next-hops in allHops, and unregisters the set difference of newHops - oldHops. This method also schedules the regular refresh of those next hops.
|name||The name prefix that the next-hops apply to|
|allHops||A complete list of next-hops to associate with name.|