face: replace EventEmitter usage with Signal
refs #2300
Change-Id: I17d0d65d2c474b17dd9f23f271a6144b0b4fbc07
diff --git a/daemon/face/face.hpp b/daemon/face/face.hpp
index 40a77a1..156a82d 100644
--- a/daemon/face/face.hpp
+++ b/daemon/face/face.hpp
@@ -78,19 +78,19 @@
~Face();
/// fires when an Interest is received
- EventEmitter<Interest> onReceiveInterest;
+ signal::Signal<Face, Interest> onReceiveInterest;
/// fires when a Data is received
- EventEmitter<Data> onReceiveData;
+ signal::Signal<Face, Data> onReceiveData;
/// fires when an Interest is sent out
- EventEmitter<Interest> onSendInterest;
+ signal::Signal<Face, Interest> onSendInterest;
/// fires when a Data is sent out
- EventEmitter<Data> onSendData;
+ signal::Signal<Face, Data> onSendData;
/// fires when face disconnects or fails to perform properly
- EventEmitter<std::string/*reason*/> onFail;
+ signal::Signal<Face, std::string/*reason*/> onFail;
/// send an Interest
virtual void
@@ -187,6 +187,11 @@
void
fail(const std::string& reason);
+ DECLARE_SIGNAL_EMIT(onReceiveInterest)
+ DECLARE_SIGNAL_EMIT(onReceiveData)
+ DECLARE_SIGNAL_EMIT(onSendInterest)
+ DECLARE_SIGNAL_EMIT(onSendData)
+
private:
void
setId(FaceId faceId);