NS-3 based Named Data Networking (NDN) simulator
ndnSIM 2.3: NDN, CCN, CCNx, content centric networks
API Documentation
strategy-choice-entry.cpp
Go to the documentation of this file.
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
27 #include "core/logger.hpp"
28 #include "fw/strategy.hpp"
29 
30 namespace nfd {
31 namespace strategy_choice {
32 
33 Entry::Entry(const Name& prefix)
34  : m_prefix(prefix)
35  , m_nameTreeEntry(nullptr)
36 {
37 }
38 
39 Entry::~Entry() = default;
40 
41 const Name&
43 {
44  return this->getStrategy().getInstanceName();
45 }
46 
47 void
48 Entry::setStrategy(unique_ptr<fw::Strategy> strategy)
49 {
50  m_strategy = std::move(strategy);
51 }
52 
53 } // namespace strategy_choice
54 } // namespace nfd
const Name & getStrategyInstanceName() const
const Name & getInstanceName() const
Definition: strategy.hpp:110
fw::Strategy & getStrategy() const
Copyright (c) 2011-2015 Regents of the University of California.
Definition: ndn-common.hpp:40
Represents an absolute name.
Definition: name.hpp:42
void setStrategy(unique_ptr< fw::Strategy > strategy)