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
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
15 \brief CommunicationPolicy inline template implementation
18 //#include "CommunicationPolicy.ih"
22 #define prefix_ inline
23 //-/////////////////////////////////////////////////////////////////////////////////////////////////
26 template <class SPolicy>
27 prefix_ void senf::ConnectedCommunicationPolicy::
28 listen(ServerSocketHandle<SPolicy> const & handle, unsigned backlog,
29 typename IfAddressingPolicyIsNot<SPolicy,NoAddressingPolicy>::type *)
31 do_listen(handle, backlog);
34 template <class SPolicy>
35 prefix_ void senf::ConnectedCommunicationPolicy::
36 listen(ServerSocketHandle<SPolicy> const & handle, unsigned backlog)
41 template <class SPolicy>
42 prefix_ int senf::ConnectedCommunicationPolicy::
43 accept(ServerSocketHandle<SPolicy> const & handle,
44 typename ServerSocketHandle<SPolicy>::Address & address,
45 typename IfAddressingPolicyIsNot<SPolicy,NoAddressingPolicy>::type *)
47 return do_accept(handle,address.sockaddr_p(),address.socklen());
50 template <class SPolicy>
51 prefix_ int senf::ConnectedCommunicationPolicy::
52 accept(ServerSocketHandle<SPolicy> const & handle,
53 typename ServerSocketHandle<SPolicy>::Address & address)
57 //-/////////////////////////////////////////////////////////////////////////////////////////////////
64 // c-file-style: "senf"
65 // indent-tabs-mode: nil
66 // ispell-local-dictionary: "american"
67 // compile-command: "scons -u test"