NS-3 based Named Data Networking (NDN) simulator
ndnSIM 2.0: NDN, CCN, CCNx, content centric networks
API Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
nfd::CommandValidator Class Reference

#include <command-validator.hpp>

Classes

class  Error
 

Public Member Functions

 CommandValidator ()
 
 ~CommandValidator ()
 
void setConfigFile (ConfigFile &configFile)
 
void onConfig (const ConfigSection &section, bool isDryRun, const std::string &filename)
 
void addSupportedPrivilege (const std::string &privilege)
 
void addInterestRule (const std::string &regex, const ndn::IdentityCertificate &certificate)
 
void addInterestRule (const std::string &regex, const Name &keyName, const ndn::PublicKey &publicKey)
 
void validate (const Interest &interest, const ndn::OnInterestValidated &onValidated, const ndn::OnInterestValidationFailed &onValidationFailed)
 

Detailed Description

Definition at line 34 of file command-validator.hpp.

Constructor & Destructor Documentation

nfd::CommandValidator::CommandValidator ( )

Definition at line 38 of file command-validator.cpp.

nfd::CommandValidator::~CommandValidator ( )

Definition at line 43 of file command-validator.cpp.

Member Function Documentation

void nfd::CommandValidator::addInterestRule ( const std::string &  regex,
const ndn::IdentityCertificate &  certificate 
)
inline

Definition at line 92 of file command-validator.hpp.

void nfd::CommandValidator::addInterestRule ( const std::string &  regex,
const Name &  keyName,
const ndn::PublicKey &  publicKey 
)
inline

Definition at line 99 of file command-validator.hpp.

void nfd::CommandValidator::addSupportedPrivilege ( const std::string &  privilege)
Parameters
privilegename of privilege to add
Exceptions
CommandValidator::Erroron duplicated privilege

Definition at line 213 of file command-validator.cpp.

void nfd::CommandValidator::onConfig ( const ConfigSection section,
bool  isDryRun,
const std::string &  filename 
)
Parameters
section"authorizations" section to parse
isDryRuntrue if performing a dry run of configuration, false otherwise
filenamefilename of configuration file
Exceptions
ConfigFile::Erroron parse error

Definition at line 66 of file command-validator.cpp.

References nfd::aggregateErrors(), NFD_LOG_DEBUG, NFD_LOG_INFO, and NFD_LOG_WARN.

Referenced by setConfigFile().

void nfd::CommandValidator::setConfigFile ( ConfigFile configFile)

Definition at line 49 of file command-validator.cpp.

References nfd::ConfigFile::addSectionHandler(), and onConfig().

void nfd::CommandValidator::validate ( const Interest &  interest,
const ndn::OnInterestValidated &  onValidated,
const ndn::OnInterestValidationFailed &  onValidationFailed 
)
inline

Definition at line 107 of file command-validator.hpp.


The documentation for this class was generated from the following files: