NS-3 based Named Data Networking (NDN) simulator
ndnSIM 2.0: NDN, CCN, CCNx, content centric networks
API Documentation
fib-update.cpp
Go to the documentation of this file.
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
26 #include "fib-update.hpp"
27 
28 namespace nfd {
29 namespace rib {
30 
32 FibUpdate::createAddUpdate(const Name& name, const uint64_t faceId, const uint64_t cost)
33 {
34  FibUpdate update;
35 
36  update.name = name;
37  update.faceId = faceId;
38  update.cost = cost;
39  update.action = ADD_NEXTHOP;
40 
41  return update;
42 }
43 
46 {
47  FibUpdate update;
48 
49  update.name = name;
50  update.faceId = faceId;
51  update.action = REMOVE_NEXTHOP;
52 
53  return update;
54 }
55 
56 } // namespace rib
57 } // namespace nfd
represents a FIB update
Definition: fib-update.hpp:37
static FibUpdate createRemoveUpdate(const Name &name, const uint64_t faceId)
Definition: fib-update.cpp:45
Copyright (c) 2011-2015 Regents of the University of California.
Definition: ndn-common.hpp:38
static FibUpdate createAddUpdate(const Name &name, const uint64_t faceId, const uint64_t cost)
Definition: fib-update.cpp:32
Name abstraction to represent an absolute name.
Definition: name.hpp:46