]> git.ipfire.org Git - thirdparty/squid.git/blob - src/mgr/QueryParam.h
SourceFormat Enforcement
[thirdparty/squid.git] / src / mgr / QueryParam.h
1 /*
2 * $Id$
3 *
4 * DEBUG: section 16 Cache Manager API
5 *
6 */
7
8 #ifndef SQUID_MGR_QUERY_PARAM_H
9 #define SQUID_MGR_QUERY_PARAM_H
10
11 #include "ipc/forward.h"
12 #include "RefCount.h"
13
14 namespace Mgr
15 {
16
17 class QueryParam: public RefCountable
18 {
19 public:
20 typedef enum {ptInt = 1, ptString} Type;
21 typedef RefCount<QueryParam> Pointer;
22
23 public:
24 QueryParam(Type aType): type(aType) {}
25 virtual ~QueryParam() {}
26 virtual void pack(Ipc::TypedMsgHdr& msg) const = 0; ///< store parameter into msg
27 virtual void unpackValue(const Ipc::TypedMsgHdr& msg) = 0; ///< load parameter value from msg
28
29 private:
30 QueryParam(const QueryParam&); // not implemented
31 QueryParam& operator= (const QueryParam&); // not implemented
32
33 public:
34 Type type;
35 };
36
37 } // namespace Mgr
38
39 #endif /* SQUID_MGR_QUERY_PARAM_H */