Kea 2.7.5
io_socket.cc
Go to the documentation of this file.
1// Copyright (C) 2010-2024 Internet Systems Consortium, Inc. ("ISC")
2//
3// This Source Code Form is subject to the terms of the Mozilla Public
4// License, v. 2.0. If a copy of the MPL was not distributed with this
5// file, You can obtain one at http://mozilla.org/MPL/2.0/.
6
7#include <config.h>
10
11namespace isc {
12namespace asiolink {
13
20class DummySocket : public IOSocket {
21private:
22 DummySocket(const DummySocket& source);
23 DummySocket& operator=(const DummySocket& source);
24public:
31 DummySocket(const int protocol) : protocol_(protocol) {}
32
37 virtual int getNative() const { return (-1); }
38
39 virtual int getProtocol() const { return (protocol_); }
40private:
41 const int protocol_;
42};
43
44IOSocket&
46 static DummySocket socket(IPPROTO_UDP);
47 return (socket);
48}
49
52 static DummySocket socket(IPPROTO_TCP);
53 return (socket);
54}
55
56} // namespace asiolink
57} // namespace isc
Defines the logger used by the top-level component of kea-lfc.