Factory.h
Go to the documentation of this file.
1 /****
2  * Sming Framework Project - Open Source framework for high efficiency native ESP8266 development.
3  * Created 2015 by Skurydin Alexey
4  * http://github.com/SmingHub/Sming
5  * All files of the Sming Core are provided under the LGPL v3 license.
6  *
7  * Factory.h
8  *
9  * @author: 2019 - Slavey Karadzhov <slav@attachix.com>
10  *
11  ****/
12 
13 #pragma once
14 
15 #include "Context.h"
16 
17 namespace Ssl
18 {
23 class Factory
24 {
25 public:
26  virtual ~Factory()
27  {
28  }
29 
34  virtual Context* createContext(Session& session) = 0;
35 };
36 
40 extern Factory* factory;
41 
42 } // namespace Ssl
Implemented by SSL adapter to create and manage SSL connections.
Definition: Components/ssl/include/Network/Ssl/Context.h:29
Implemented by SSL adapter.
Definition: Factory.h:24
virtual ~Factory()
Definition: Factory.h:26
virtual Context * createContext(Session &session)=0
Create SSL context that can be used to create new client or server connections.
Handles all SSL activity for a TCP connection.
Definition: Session.h:78
Definition: Alert.h:16
Factory * factory
Provided by ssl adapter, NULL if SSL is disabled.