CppServer  1.0.4.0
C++ Server Library
asio.inl
Go to the documentation of this file.
1 
9 namespace CppServer {
10 namespace Asio {
11 
12 template <class TOutputStream>
13 inline TOutputStream& operator<<(TOutputStream& stream, InternetProtocol protocol)
14 {
15  switch (protocol)
16  {
18  stream << "IPv4";
19  break;
21  stream << "IPv6";
22  break;
23  default:
24  stream << "<unknown>";
25  break;
26  }
27  return stream;
28 }
29 
30 } // namespace Asio
31 } // namespace CppServer
TOutputStream & operator<<(TOutputStream &stream, InternetProtocol protocol)
Stream output: Internet protocol.
Definition: asio.inl:13
InternetProtocol
Internet protocol.
Definition: asio.h:66
@ IPv4
Internet Protocol version 4.
@ IPv6
Internet Protocol version 6.
C++ Server project definitions.
Definition: asio.h:56