39 BOOST_THROW_EXCEPTION(std::invalid_argument(
"MulticastStrategy does not accept parameters"));
42 BOOST_THROW_EXCEPTION(std::invalid_argument(
43 "MulticastStrategy does not support version " + std::to_string(*parsed.
version)));
51 static Name strategyName(
"/localhost/nfd/strategy/multicast/%FD%01");
57 const shared_ptr<pit::Entry>& pitEntry)
62 for (fib::NextHopList::const_iterator it = nexthops.begin(); it != nexthops.end(); ++it) {
63 Face& outFace = it->getFace();
bool canForwardToLegacy(const pit::Entry &pitEntry, const Face &face)
decide whether Interest can be forwarded to face
void setInstanceName(const Name &name)
set strategy instance name
void sendInterest(const shared_ptr< pit::Entry > &pitEntry, Face &outFace, const Interest &interest)
send Interest to outFace
static Name makeInstanceName(const Name &input, const Name &strategyName)
construct a strategy instance name
static const Name & getStrategyName()
virtual void afterReceiveInterest(const Face &inFace, const Interest &interest, const shared_ptr< pit::Entry > &pitEntry) override
trigger after Interest is received
Copyright (c) 2014-2015, Regents of the University of California, Arizona Board of Regents...
#define NFD_REGISTER_STRATEGY(S)
registers a strategy
std::vector< fib::NextHop > NextHopList
MulticastStrategy(Forwarder &forwarder, const Name &name=getStrategyName())
PartialName parameters
parameter components
bool hasPendingOutRecords(const pit::Entry &pitEntry)
determine whether pitEntry has any pending out-records
ndn::optional< uint64_t > version
whether strategyName contains a version component
represents a forwarding strategy
Copyright (c) 2014-2016, Regents of the University of California, Arizona Board of Regents...
static ParsedInstanceName parseInstanceName(const Name &input)
parse a strategy instance name
bool wouldViolateScope(const Face &inFace, const Interest &interest, const Face &outFace)
determine whether forwarding the Interest in pitEntry to outFace would violate scope ...
const NextHopList & getNextHops() const
void rejectPendingInterest(const shared_ptr< pit::Entry > &pitEntry)
decide that a pending Interest cannot be forwarded
const fib::Entry & lookupFib(const pit::Entry &pitEntry) const
performs a FIB lookup, considering Link object if present