]>
Commit | Line | Data |
---|---|---|
8822ebee | 1 | /* |
4ac4a490 | 2 | * Copyright (C) 1996-2017 The Squid Software Foundation and contributors |
8822ebee | 3 | * |
bbc27441 AJ |
4 | * Squid software is distributed under GPLv2+ license and includes |
5 | * contributions from numerous individuals and organizations. | |
6 | * Please see the COPYING and CONTRIBUTORS files for details. | |
8822ebee AR |
7 | */ |
8 | ||
bbc27441 AJ |
9 | /* DEBUG: section 16 Cache Manager API */ |
10 | ||
8822ebee AR |
11 | #ifndef SQUID_MGR_ACTION_CREATOR_H |
12 | #define SQUID_MGR_ACTION_CREATOR_H | |
13 | ||
14 | #include "mgr/forward.h" | |
15 | ||
16 | namespace Mgr | |
17 | { | |
18 | ||
19 | /** Creates objects of the right Action class, parameterized with Command. | |
20 | * A part of the Action profile that allows Cache Manager be ignorant about | |
21 | * specific Action classes (\see Mgr::ActionProfile). | |
22 | */ | |
23 | class ActionCreator: public RefCountable | |
24 | { | |
25 | public: | |
26 | typedef RefCount<ActionCreator> Pointer; | |
27 | ||
28 | virtual ~ActionCreator() {} | |
29 | ||
30 | /// returns a pointer to the new Action object for cmd; never nil | |
31 | virtual ActionPointer create(const CommandPointer &cmd) const = 0; | |
32 | }; | |
33 | ||
34 | } // namespace Mgr | |
35 | ||
36 | #endif /* SQUID_MGR_ACTION_CREATOR_H */ | |
f53969cc | 37 |