NS-3 based Named Data Networking (NDN) simulator
ndnSIM 2.5: NDN, CCN, CCNx, content centric networks
API Documentation
nfd-face-event-notification.hpp
Go to the documentation of this file.
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
22 #ifndef NDN_MANAGEMENT_NFD_FACE_EVENT_NOTIFICATION_HPP
23 #define NDN_MANAGEMENT_NFD_FACE_EVENT_NOTIFICATION_HPP
24 
25 #include "nfd-face-traits.hpp"
26 #include "../encoding/block.hpp"
27 
28 namespace ndn {
29 namespace nfd {
30 
37 };
38 
44 class FaceEventNotification : public FaceTraits<FaceEventNotification>
45 {
46 public:
48 
49  explicit
50  FaceEventNotification(const Block& block);
51 
54  template<encoding::Tag TAG>
55  size_t
56  wireEncode(EncodingImpl<TAG>& encoder) const;
57 
60  const Block&
61  wireEncode() const;
62 
65  void
66  wireDecode(const Block& wire);
67 
68 public: // getters & setters
70  getKind() const
71  {
72  return m_kind;
73  }
74 
76  setKind(FaceEventKind kind);
77 
78 protected:
79  void
80  wireReset() const;
81 
82 private:
83  FaceEventKind m_kind;
84 
85  mutable Block m_wire;
86 };
87 
88 std::ostream&
89 operator<<(std::ostream& os, const FaceEventNotification& notification);
90 
91 } // namespace nfd
92 } // namespace ndn
93 
94 #endif // NDN_MANAGEMENT_NFD_FACE_EVENT_NOTIFICATION_HPP
Copyright (c) 2011-2015 Regents of the University of California.
represents a Face status change notification
Class representing a wire element of NDN-TLV packet format.
Definition: block.hpp:43
FaceEventNotification & setKind(FaceEventKind kind)
Copyright (c) 2011-2015 Regents of the University of California.
Definition: ndn-common.hpp:40
std::ostream & operator<<(std::ostream &os, FaceScope faceScope)
providers getters and setters of face information fields
const Block & wireEncode() const
encode FaceEventNotification
void wireDecode(const Block &wire)
decode FaceEventNotification