1//
2// HTTPSSessionInstantiator.h
3//
4// Library: NetSSL_OpenSSL
5// Package: HTTPSClient
6// Module: HTTPSSessionInstantiator
7//
8// Definition of the HTTPSSessionInstantiator class.
9//
10// Copyright (c) 2006-2009, Applied Informatics Software Engineering GmbH.
11// and Contributors.
12//
13// SPDX-License-Identifier: BSL-1.0
14//
15
16
17#ifndef Net_HTTPSSessionInstantiator_INCLUDED
18#define Net_HTTPSSessionInstantiator_INCLUDED
19
20
21#include "Poco/Net/NetSSL.h"
22#include "Poco/Net/Context.h"
23#include "Poco/Net/Utility.h"
24#include "Poco/Net/HTTPSessionInstantiator.h"
25#include "Poco/URI.h"
26
27
28namespace Poco {
29namespace Net {
30
31
32class NetSSL_API HTTPSSessionInstantiator: public HTTPSessionInstantiator
33 /// The HTTPSessionInstantiator for HTTPSClientSession.
34{
35public:
36 HTTPSSessionInstantiator();
37 /// Creates the HTTPSSessionInstantiator.
38
39 HTTPSSessionInstantiator(Context::Ptr pContext);
40 /// Creates the HTTPSSessionInstantiator using the given SSL context.
41
42 ~HTTPSSessionInstantiator();
43 /// Destroys the HTTPSSessionInstantiator.
44
45 HTTPClientSession* createClientSession(const Poco::URI& uri);
46 /// Creates a HTTPSClientSession for the given URI.
47
48 static void registerInstantiator();
49 /// Registers the instantiator with the global HTTPSessionFactory.
50
51 static void registerInstantiator(Context::Ptr pContext);
52 /// Registers the instantiator with the global HTTPSessionFactory using the given SSL context.
53
54 static void unregisterInstantiator();
55 /// Unregisters the factory with the global HTTPSessionFactory.
56
57private:
58 Context::Ptr _pContext;
59};
60
61
62} } // namespace Poco::Net
63
64
65#endif // Net_HTTPSSessionInstantiator_INCLUDED
66