UDPSocketHandle.hh
Go to the documentation of this file.
1 //
2 // Copyright (c) 2020 Fraunhofer Institute for Applied Information Technology (FIT)
3 // Network Research Group (NET)
4 // Schloss Birlinghoven, 53754 Sankt Augustin, GERMANY
5 // Contact: support@wiback.org
6 //
7 // This file is part of the SENF code tree.
8 // It is licensed under the 3-clause BSD License (aka New BSD License).
9 // See LICENSE.txt in the top level directory for details or visit
10 // https://opensource.org/licenses/BSD-3-Clause
11 //
12 
13 
21 #ifndef HH_SENF_Socket_Protocols_INet_UDPSocketHandle_
22 #define HH_SENF_Socket_Protocols_INet_UDPSocketHandle_ 1
23 
24 // Custom includes
25 #include "INetAddressing.hh"
26 #include "UDPSocketProtocol.hh"
34 
35 //#include "UDPSocketHandle.mpp"
36 //-/////////////////////////////////////////////////////////////////////////////////////////////////
37 
38 namespace senf {
39 
41  //\{
42 
43  typedef MakeSocketPolicy<
44  INet4AddressingPolicy,
45  DatagramFramingPolicy,
46  UnconnectedCommunicationPolicy,
47  ReadablePolicy,
48  WriteablePolicy
49  >::policy UDPv4Socket_Policy;
50 
72  : public ConcreteSocketProtocol<UDPv4Socket_Policy, UDPv4SocketProtocol>,
73  public UDPSocketProtocol,
75  public BSDSocketProtocol,
78  {
79  public:
80  //-////////////////////////////////////////////////////////////////////////
81  // internal interface
82 
84  //\{
85 
86  void init_client() const;
87 
90  void init_client(INet4SocketAddress const & address) const;
92 
99  //\}
100 
101  };
102 
104 
105  typedef MakeSocketPolicy<
109 
131  : public ConcreteSocketProtocol<UDPv6Socket_Policy, UDPv6SocketProtocol>,
132  public UDPSocketProtocol,
134  public BSDSocketProtocol,
135  public DatagramSocketProtocol,
137  {
138  public:
139  //-////////////////////////////////////////////////////////////////////////
140  // internal interface
141 
143  //\{
144 
145  void init_client() const;
146 
149  void init_client(INet6SocketAddress const & address) const;
151 
158  //\}
159  };
160 
162 
163  //\}
164 
165 }
166 
167 //-/////////////////////////////////////////////////////////////////////////////////////////////////
168 //#include "UDPSocketHandle.cci"
169 //#include "UDPSocketHandle.ct"
170 //#include "UDPSocketHandle.cti"
171 #endif
172 
173 
174 // Local Variables:
175 // mode: c++
176 // fill-column: 100
177 // c-file-style: "senf"
178 // indent-tabs-mode: nil
179 // ispell-local-dictionary: "american"
180 // compile-command: "scons -u test"
181 // comment-column: 40
182 // End:
Addressing policy supporting IPv6 addressing.
CommunicationPolicy public header.
IPv6 UDP Socket Protocol.
Multicast protocol facet for INet4 addressable multicast enabled sockets.
IPv4 UDP Socket Protocol.
IPv6 socket address.
ProtocolClientSocketHandle public header.
MulticastSocketProtocol public header.
ProtocolClientSocketHandle< UDPv6SocketProtocol > UDPv6ClientSocketHandle
IPv4 socket address.
DatagramSocketProtocol public header.
Multicast protocol facet for INet6 addressable multicast enabled sockets.
ReadPolicy and WritePolicy public header.
Protocol facet providing basic BSD socket functionality.
MakeSocketPolicy< UDPv4Socket_Policy, INet6AddressingPolicy >::policy UDPv6Socket_Policy
Protocol facet providing basic connection oriented BSD socket functions.
UDPSocketProtocol public header.
Protocol specific socket handle (client interface)
MakeSocketPolicy< INet4AddressingPolicy, DatagramFramingPolicy, UnconnectedCommunicationPolicy, ReadablePolicy, WriteablePolicy >::policy UDPv4Socket_Policy
Socket Policy of the UDPv4 Protocol.
BSDSocketProtocol public header.
Concrete Socket Protocol implementation base class.
INet[46]Address and INet[46]AddressingPolicy public header.
FramingPolicy public header.
Protocol facet to support UDP operations.
void init_client() const
Create unconnected client socket.
ProtocolClientSocketHandle< UDPv4SocketProtocol > UDPv4ClientSocketHandle
Metafunction to create SocketPolicy.
Protocol facet providing generic BSD datagram socket functionality.