22 #ifndef NDN_UTIL_DUMMY_CLIENT_FACE_HPP 23 #define NDN_UTIL_DUMMY_CLIENT_FACE_HPP 25 #include "../face.hpp" 27 #include "../security/key-chain.hpp" 44 : enablePacketLogging(enablePacketLogging)
45 , enableRegistrationReply(enableRegistrationReply)
50 Options(
bool enablePacketLogging,
bool enableRegistrationReply)
51 :
Options(enablePacketLogging, enableRegistrationReply, nullptr)
114 construct(
const Options& options);
169 std::unique_ptr<KeyChain> m_internalKeyChain;
171 std::function<void(time::milliseconds)> m_processEventsOverride;
177 #endif // NDN_UTIL_DUMMY_CLIENT_FACE_HPP bool enableRegistrationReply
if true, prefix registration command will be automatically replied with a successful response ...
std::vector< lp::Nack > sentNacks
Nacks sent out of this DummyClientFace.
Copyright (c) 2011-2015 Regents of the University of California.
Signal< DummyClientFace, Interest > onSendInterest
emits whenever an Interest is sent
std::vector< Interest > sentInterests
Interests sent out of this DummyClientFace.
boost::posix_time::time_duration milliseconds(long duration)
represents an Interest packet
std::vector< Data > sentData
Data sent out of this DummyClientFace.
represents a Network Nack
options for DummyClientFace
DummyClientFace(const Options &options=Options())
Create a dummy face with internal IO service.
Signal< DummyClientFace, lp::Nack > onSendNack
emits whenever a Nack is sent
Provide a communication channel with local or remote NDN forwarder.
Signal< DummyClientFace, Data > onSendData
emits whenever a Data packet is sent
void receive(const Interest &interest)
cause the Face to receive an interest
a client-side face for unit testing
Options(bool enablePacketLogging, bool enableRegistrationReply)
Options(bool enablePacketLogging, bool enableRegistrationReply, const std::function< void(time::milliseconds)> &processEventsOverride)
Represents a Data packet.
bool enablePacketLogging
if true, packets sent out of DummyClientFace will be appended to a container
std::function< void(time::milliseconds)> processEventsOverride
if not empty, face.processEvents() will be overridden by this function