face: implement close-on-idle and persistency change for Ethernet unicast

Change-Id: I255024990a72b8cea5a44fa89f515ad91aadba66
Refs: #4011
diff --git a/daemon/face/unicast-ethernet-transport.hpp b/daemon/face/unicast-ethernet-transport.hpp
index b1a856b..d85dfc7 100644
--- a/daemon/face/unicast-ethernet-transport.hpp
+++ b/daemon/face/unicast-ethernet-transport.hpp
@@ -27,6 +27,7 @@
 #define NFD_DAEMON_FACE_UNICAST_ETHERNET_TRANSPORT_HPP
 
 #include "ethernet-transport.hpp"
+#include "core/scheduler.hpp"
 
 namespace nfd {
 namespace face {
@@ -45,8 +46,20 @@
                            ndn::nfd::FacePersistency persistency,
                            time::nanoseconds idleTimeout);
 
+protected:
+  bool
+  canChangePersistencyToImpl(ndn::nfd::FacePersistency newPersistency) const final;
+
+  void
+  afterChangePersistency(ndn::nfd::FacePersistency oldPersistency) final;
+
+private:
+  void
+  scheduleClosureWhenIdle();
+
 private:
   const time::nanoseconds m_idleTimeout;
+  scheduler::ScopedEventId m_closeIfIdleEvent;
 };
 
 } // namespace face