]>
git.ipfire.org Git - thirdparty/squid.git/blob - src/acl/HasComponentData.h
2 * Copyright (C) 1996-2023 The Squid Software Foundation and contributors
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.
9 #ifndef SQUID_SRC_ACL_HASCOMPONENTDATA_H
10 #define SQUID_SRC_ACL_HASCOMPONENTDATA_H
12 #include "acl/Checklist.h"
16 class ACLHasComponentData
: public ACLData
<ACLChecklist
*>
18 MEMPROXY_CLASS(ACLHasComponentData
);
21 ACLHasComponentData();
24 bool match(ACLChecklist
*) override
;
25 SBufList
dump() const override
;
26 void parse() override
;
27 bool empty() const override
{ return false; }
30 enum ComponentKind
{ coRequest
= 0, coResponse
, coAle
, coEnd
};
31 void parseComponent(const char *token
);
33 static const SBuf RequestStr
;
34 static const SBuf ResponseStr
;
35 static const SBuf AleStr
;
37 typedef bool (ACLChecklist::*ComponentCheck
)() const;
38 /// component check callbacks, ordered by component kind ID
39 std::vector
<ComponentCheck
> componentMethods
;
42 #endif /* SQUID_SRC_ACL_HASCOMPONENTDATA_H */