a collection of common functions shared by all NFD managers and RIB manager, such as communicating with the dispatcher and command validator. More...
#include <manager-base.hpp>
Classes | |
class | Error |
Public Member Functions | |
ManagerBase (Dispatcher &dispatcher, const std::string &module) | |
virtual | ~ManagerBase () |
const std::string & | getModule () const |
Protected Types | |
typedef function< void(const ControlCommand &command, const Name &prefix, const Interest &interest, const ControlParameters ¶meters, const ndn::mgmt::CommandContinuation done)> | ControlCommandHandler |
Protected Member Functions | |
template<typename Command > | |
void | registerCommandHandler (const std::string &verb, const ControlCommandHandler &handler) |
void | registerStatusDatasetHandler (const std::string &verb, const ndn::mgmt::StatusDatasetHandler &handler) |
ndn::mgmt::PostNotification | registerNotificationStream (const std::string &verb) |
void | extractRequester (const Interest &interest, ndn::mgmt::AcceptContinuation accept) |
extract a requester from a ControlCommand request More... | |
a collection of common functions shared by all NFD managers and RIB manager, such as communicating with the dispatcher and command validator.
Definition at line 48 of file manager-base.hpp.
|
protected |
Definition at line 78 of file manager-base.hpp.
nfd::ManagerBase::ManagerBase | ( | Dispatcher & | dispatcher, |
const std::string & | module | ||
) |
Definition at line 33 of file manager-base.cpp.
References ~ManagerBase().
Referenced by nfd::ManagerBase::Error::Error().
|
virtualdefault |
Referenced by nfd::ManagerBase::Error::Error(), and ManagerBase().
|
inline |
Definition at line 68 of file manager-base.hpp.
References PUBLIC_WITH_TESTS_ELSE_PROTECTED.
Referenced by nfd::NfdManagerBase::NfdManagerBase().
|
inlineprotected |
Definition at line 156 of file manager-base.hpp.
|
protected |
Definition at line 42 of file manager-base.cpp.
References ndn::mgmt::Dispatcher::addStatusDataset(), and ndn::mgmt::makeAcceptAllAuthorization().
Referenced by nfd::FaceManager::FaceManager(), nfd::FibManager::FibManager(), nfd::rib::RibManager::RibManager(), and nfd::StrategyChoiceManager::StrategyChoiceManager().
|
protected |
Definition at line 51 of file manager-base.cpp.
References ndn::mgmt::Dispatcher::addNotificationStream().
Referenced by nfd::FaceManager::FaceManager().
|
protected |
extract a requester from a ControlCommand request
This is called after the signature is validated.
interest | a request for ControlCommand |
accept | callback of successful validation, take the requester string as a argument |
Definition at line 57 of file manager-base.cpp.
References websocketpp::extensions::permessage_deflate::mode::accept, ndn::Name::at(), ndn::Block::blockFromValue(), ndn::Interest::getName(), ndn::KeyLocator::KeyLocator_Name, ndn::signed_interest::POS_SIG_INFO, and ndn::nfd::ControlCommand::validateRequest().
Referenced by nfd::rib::RibManager::onRibUpdateFailure().