]> git.stg.codes - stg.git/blob - projects/stargazer/plugins/configuration/rpcconfig/info_methods.h
Добавление исходников
[stg.git] / projects / stargazer / plugins / configuration / rpcconfig / info_methods.h
1 #ifndef __INFO_METHODS_H__
2 #define __INFO_METHODS_H__
3
4 #include <xmlrpc-c/base.hpp>
5 #include <xmlrpc-c/registry.hpp>
6
7 #include "../../../users.h"
8 #include "../../../tariffs.h"
9 #include "../../../settings.h"
10
11 // Forward declaration
12 class RPC_CONFIG;
13
14 class METHOD_INFO : public xmlrpc_c::method
15 {
16 public:
17     METHOD_INFO(TARIFFS * t,
18                 USERS * u,
19                 const SETTINGS * s)
20         : tariffs(t),
21           users(u),
22           settings(s)
23     {
24     }
25
26     void execute(xmlrpc_c::paramList const & paramList,
27                  xmlrpc_c::value *   const   retvalP);
28 private:
29     TARIFFS * tariffs;
30     USERS * users;
31     const SETTINGS * settings;
32 };
33
34 class METHOD_LOGIN : public xmlrpc_c::method
35 {
36 public:
37     METHOD_LOGIN(RPC_CONFIG * c)
38         : config(c)
39     {
40     }
41
42     void execute(xmlrpc_c::paramList const & paramList,
43                  xmlrpc_c::value *   const   retvalP);
44 private:
45     RPC_CONFIG * config;
46 };
47
48 class METHOD_LOGOUT : public xmlrpc_c::method
49 {
50 public:
51     METHOD_LOGOUT(RPC_CONFIG * c)
52         : config(c)
53     {
54     }
55
56     void execute(xmlrpc_c::paramList const & paramList,
57                  xmlrpc_c::value *   const   retvalP);
58 private:
59     RPC_CONFIG * config;
60 };
61
62 #endif