]> git.ipfire.org Git - thirdparty/squid.git/blob - src/mgr/ActionCreator.h
merge from trunk r12441
[thirdparty/squid.git] / src / mgr / ActionCreator.h
1 /*
2 * DEBUG: section 16 Cache Manager API
3 *
4 */
5
6 #ifndef SQUID_MGR_ACTION_CREATOR_H
7 #define SQUID_MGR_ACTION_CREATOR_H
8
9 #include "mgr/forward.h"
10
11 namespace Mgr
12 {
13
14 /** Creates objects of the right Action class, parameterized with Command.
15 * A part of the Action profile that allows Cache Manager be ignorant about
16 * specific Action classes (\see Mgr::ActionProfile).
17 */
18 class ActionCreator: public RefCountable
19 {
20 public:
21 typedef RefCount<ActionCreator> Pointer;
22
23 virtual ~ActionCreator() {}
24
25 /// returns a pointer to the new Action object for cmd; never nil
26 virtual ActionPointer create(const CommandPointer &cmd) const = 0;
27 };
28
29 } // namespace Mgr
30
31 #endif /* SQUID_MGR_ACTION_CREATOR_H */