]> git.ipfire.org Git - thirdparty/squid.git/blame - src/mgr/BasicActions.h
Docs: Copyright updates for 2018 (#114)
[thirdparty/squid.git] / src / mgr / BasicActions.h
CommitLineData
8822ebee 1/*
5b74111a 2 * Copyright (C) 1996-2018 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_BASIC_ACTIONS_H
12#define SQUID_MGR_BASIC_ACTIONS_H
13
14#include "mgr/Action.h"
15
16/* a collection of simple, mostly stateless actions */
17
8822ebee
AR
18namespace Mgr
19{
20
b073fc4b
AJ
21/// A dummy action placeholder for the no-action requests
22/// a templated Cache Manager index ('home') page.
23/// Display output is produced directly by the receiving worker
24/// without invoking the co-ordinator or action Job.
25class IndexAction: public Action
26{
27public:
28 static Pointer Create(const CommandPointer &cmd);
29 /* Action API */
30 virtual void dump(StoreEntry *entry);
31
32protected:
33 IndexAction(const CommandPointer &cmd);
34};
35
8822ebee
AR
36/// returns available Cache Manager actions and their access requirements
37class MenuAction: public Action
38{
39public:
40 static Pointer Create(const CommandPointer &cmd);
41 /* Action API */
42 virtual void dump(StoreEntry *entry);
43
44protected:
45 MenuAction(const CommandPointer &cmd);
46};
47
8822ebee
AR
48/// shuts Squid down
49class ShutdownAction: public Action
50{
51public:
52 static Pointer Create(const CommandPointer &cmd);
53 /* Action API */
54 virtual void dump(StoreEntry *entry);
55
56protected:
57 ShutdownAction(const CommandPointer &cmd);
58};
59
60/// reconfigures Squid
61class ReconfigureAction: public Action
62{
63public:
64 static Pointer Create(const CommandPointer &cmd);
65 /* Action API */
66 virtual void dump(StoreEntry *entry);
67
68protected:
69 ReconfigureAction(const CommandPointer &cmd);
70};
71
72/// starts log rotation
73class RotateAction: public Action
74{
75public:
76 static Pointer Create(const CommandPointer &cmd);
77 /* Action API */
78 virtual void dump(StoreEntry *entry);
79
80protected:
81 RotateAction(const CommandPointer &cmd);
82};
83
84/// changes offline mode
85class OfflineToggleAction: public Action
86{
87public:
88 static Pointer Create(const CommandPointer &cmd);
89 /* Action API */
90 virtual void dump(StoreEntry *entry);
91
92protected:
93 OfflineToggleAction(const CommandPointer &cmd);
94};
95
96/// Registeres profiles for the actions above; \todo move elsewhere?
97void RegisterBasics();
98
99} // namespace Mgr
100
101#endif /* SQUID_MGR_BASIC_ACTIONS_H */
f53969cc 102