1 | /************************************************************************* |
2 | * libjson-rpc-cpp |
3 | ************************************************************************* |
4 | * @file requesthandlerfactory.h |
5 | * @date 10/23/2014 |
6 | * @author Peter Spiess-Knafl <dev@spiessknafl.at> |
7 | * @license See attached LICENSE.txt |
8 | ************************************************************************/ |
9 | |
10 | #ifndef JSONRPC_REQUESTHANDLERFACTORY_H |
11 | #define JSONRPC_REQUESTHANDLERFACTORY_H |
12 | |
13 | #include "iclientconnectionhandler.h" |
14 | #include "iprocedureinvokationhandler.h" |
15 | |
16 | namespace jsonrpc { |
17 | |
18 | typedef enum { JSONRPC_SERVER_V1, JSONRPC_SERVER_V2, JSONRPC_SERVER_V1V2 } serverVersion_t; |
19 | |
20 | class RequestHandlerFactory { |
21 | public: |
22 | static IProtocolHandler *createProtocolHandler(serverVersion_t type, IProcedureInvokationHandler &handler); |
23 | }; |
24 | |
25 | } // namespace jsonrpc |
26 | |
27 | #endif // JSONRPC_REQUESTHANDLERFACTORY_H |
28 | |