22 #ifndef NLSR_HELLO_PROTOCOL_HPP 23 #define NLSR_HELLO_PROTOCOL_HPP 31 #include <ndn-cxx/util/signal.hpp> 32 #include <ndn-cxx/face.hpp> 33 #include <ndn-cxx/mgmt/nfd/control-parameters.hpp> 34 #include <ndn-cxx/mgmt/nfd/control-response.hpp> 35 #include <ndn-cxx/util/scheduler.hpp> 36 #include <ndn-cxx/security/v2/validation-error.hpp> 37 #include <ndn-cxx/security/validator-config.hpp> 45 ndn::security::SigningInfo& signingInfo,
117 processInterestTimedOut(
const ndn::Interest& interest);
122 onContent(
const ndn::Interest& interest,
const ndn::Data& data);
134 onContentValidated(
const ndn::Data& data);
140 onContentValidationFailed(
const ndn::Data& data,
141 const ndn::security::v2::ValidationError& ve);
153 onRegistrationFailure(
const ndn::nfd::ControlResponse& response,
154 const ndn::Name& name);
167 onRegistrationSuccess(
const ndn::nfd::ControlParameters& commandSuccessResult,
168 const ndn::Name& neighbor,
const ndn::time::milliseconds& timeout);
174 registerPrefixes(
const ndn::Name& adjName,
const std::string& faceUri,
175 double linkCost,
const ndn::time::milliseconds& timeout);
178 ndn::Scheduler m_scheduler;
179 ndn::security::v2::KeyChain& m_keyChain;
180 ndn::security::SigningInfo& m_signingInfo;
185 static const std::string INFO_COMPONENT;
186 static const std::string NLSR_COMPONENT;
191 #endif // NLSR_HELLO_PROTOCOL_HPP
A class to house all the configuration parameters for NLSR.
#define PUBLIC_WITH_TESTS_ELSE_PRIVATE
ndn::util::signal::Signal< HelloProtocol, Statistics::PacketType > hpIncrementSignal
void expressInterest(const ndn::Name &interestNamePrefix, uint32_t seconds)
Sends a Hello Interest packet.
HelloProtocol(ndn::Face &face, ndn::KeyChain &keyChain, ndn::security::SigningInfo &signingInfo, ConfParameter &confParam, RoutingTable &routingTable, Lsdb &lsdb)
void scheduleInterest(uint32_t seconds)
Schedules a Hello Interest event.
void processInterest(const ndn::Name &name, const ndn::Interest &interest)
Processes a Hello Interest from a neighbor.
Copyright (c) 2014-2018, The University of Memphis, Regents of the University of California, Arizona Board of Regents.
void sendScheduledInterest()
Sends Hello Interests to all neighbors.