MeVisLab Toolbox Reference
TlsAcceptorSession.h
Go to the documentation of this file.
1// Copyright (c) Fraunhofer MEVIS, Germany. All rights reserved.
2// **InsertLicense** code
3
4#pragma once
5
6#include <asio/System.h>
8#include <asio/TcpAcceptor.h>
9#include <asio/TlsSocket.h>
10
11
12namespace asio {
13
40 {
42
43 TlsAcceptorSession(std::shared_ptr<Context> io_context, std::shared_ptr<TlsContext> tls_context, const std::string& address, const unsigned short port);
44
45 public:
46
47 unsigned short port() const;
48
49 void start();
50
51 void stop();
52
53 private:
54
55 void accept();
56
57 std::shared_ptr<Context> io_context;
58 std::shared_ptr<TlsContext> tls_context;
59
60 TcpAcceptor acceptor;
61 // TlsSocket candidate;
62 };
63
64}
#define ASYNCHRONOUSIO_EXPORT
Definition System.h:10
Class template facilitating the definition of asio::Socket generators.
A TCP acceptor listening on a given port and interface address.
Definition TcpAcceptor.h:40
A TCP acceptor session with TLS support continuously waiting for incoming connections.
unsigned short port() const
Target mlrange_cast(Source arg)
Generic version of checked ML casts.