face+transport: Eliminating concept of ConnectionInfo
The current "transport" is not really a transport, rather than a
connection, which completely handles all connection-specific tasks.
I don't see any reason for not to keep connection information as
inherent property of the "transport".
Change-Id: Ib06697522d1b8f5b22d82fa86994056a9b0b7dec
diff --git a/include/ndn-cpp/face.hpp b/include/ndn-cpp/face.hpp
index 3204ae0..a0b3f0e 100644
--- a/include/ndn-cpp/face.hpp
+++ b/include/ndn-cpp/face.hpp
@@ -23,8 +23,8 @@
* @param transport A shared_ptr to a Transport object used for communication.
* @param transport A shared_ptr to a Transport::ConnectionInfo to be used to connect to the transport.
*/
- Face(const ptr_lib::shared_ptr<Transport>& transport, const ptr_lib::shared_ptr<const Transport::ConnectionInfo>& connectionInfo)
- : node_(transport, connectionInfo)
+ Face(const ptr_lib::shared_ptr<Transport>& transport)
+ : node_(transport)
{
}
@@ -34,8 +34,7 @@
* @param port The port of the NDN hub. If omitted. use 6363.
*/
Face(const char *host, unsigned short port = 6363)
- : node_(ptr_lib::shared_ptr<TcpTransport>(new TcpTransport()),
- ptr_lib::make_shared<TcpTransport::ConnectionInfo>(host, port))
+ : node_(ptr_lib::shared_ptr<TcpTransport>(new TcpTransport(host, port)))
{
}