28 #include <ndn-cxx/management/nfd-face-event-notification.hpp> 34 , m_remoteUri(remoteUri)
35 , m_localUri(localUri)
38 , m_isMultiAccess(isMultiAccess)
66 shared_ptr<Interest> i = make_shared<Interest>();
67 i->wireDecode(element);
72 shared_ptr<Data> d = make_shared<Data>();
73 d->wireDecode(element);
97 template<
typename FaceTraits>
101 traits.setFaceId(
getId())
Copyright (c) 2011-2015 Regents of the University of California.
const FaceCounters & getCounters() const
virtual ndn::nfd::FaceStatus getFaceStatus() const
void copyStatusTo(FaceTraits &traits) const
virtual bool isUp() const
Get whether underlying communication is up.
ndn::nfd::FacePersistency getPersistency() const
Get the persistency setting.
signal::Signal< Face, Interest > onSendInterest
fires when an Interest is sent out
represents the underlying protocol and address used by a Face
bool decodeAndDispatchInput(const Block &element)
represents a Face status change notification
signal::Signal< Face, Data > onReceiveData
fires when a Data is received
Class representing a wire element of NDN-TLV packet format.
represents an Interest packet
const PacketCounter & getNOutDatas() const
outgoing Data
const FaceUri & getRemoteUri() const
const PacketCounter & getNOutInterests() const
outgoing Interest
signal::Signal< Face, Data > onSendData
fires when a Data is sent out
std::string toString(const system_clock::TimePoint &timePoint, const std::string &format, const std::locale &locale)
Convert time point to string with specified format.
void fail(const std::string &reason)
fail the face and raise onFail event if it's UP; otherwise do nothing
Copyright (c) 2011-2015 Regents of the University of California.
void copyTo(R &recipient) const
copy current obseverations to a struct
signal::Signal< Face, std::string > onFail
fires when face disconnects or fails to perform properly
const PacketCounter & getNInDatas() const
incoming Data
const FaceId INVALID_FACEID
indicates an invalid FaceId
const PacketCounter & getNInInterests() const
incoming Interest
Face(const FaceUri &remoteUri, const FaceUri &localUri, bool isLocal=false, bool isMultiAccess=false)
bool isMultiAccess() const
Get whether packets sent by this face may reach multiple peers.
signal::Signal< Face, Interest > onReceiveInterest
fires when an Interest is received
const FaceUri & getLocalUri() const
bool isLocal() const
Get whether face is connected to a local app.
represents an error in TLV encoding or decoding