face: Convert to use the global IO service by all ChannelFactories

Change-Id: Ibd8d5cea142171b5700d8920eb3eedc084bbd588
diff --git a/daemon/face/tcp-channel-factory.hpp b/daemon/face/tcp-channel-factory.hpp
index 171c24f..c87cdf4 100644
--- a/daemon/face/tcp-channel-factory.hpp
+++ b/daemon/face/tcp-channel-factory.hpp
@@ -12,23 +12,17 @@
 
 namespace nfd {
 
-class TcpChannelFactory : public ChannelFactory<tcp::Endpoint, TcpChannel>
+class TcpChannelFactory : public ChannelFactory
 {
 public:
   /**
    * \brief Exception of TcpChannelFactory
    */
-  struct Error : public ChannelFactory<tcp::Endpoint, TcpChannel>::Error
+  struct Error : public ChannelFactory::Error
   {
-    Error(const std::string& what)
-      : ChannelFactory<tcp::Endpoint, TcpChannel>::Error(what)
-    {
-    }
+    Error(const std::string& what) : ChannelFactory::Error(what) {}
   };
 
-  explicit
-  TcpChannelFactory(boost::asio::io_service& ioService);
-
   /**
    * \brief Create TCP-based channel using tcp::Endpoint
    *
@@ -67,7 +61,7 @@
    * \brief Look up TcpChannel using specified local endpoint
    *
    * \returns shared pointer to the existing TcpChannel object
-   *          or empty shared pointer when such channel does not exist 
+   *          or empty shared pointer when such channel does not exist
    *
    * \throws never
    */
@@ -75,7 +69,8 @@
   find(const tcp::Endpoint& localEndpoint);
 
 private:
-  boost::asio::io_service& m_ioService;
+  typedef std::map< tcp::Endpoint, shared_ptr<TcpChannel> > ChannelMap;
+  ChannelMap m_channels;
 };
 
 } // namespace nfd