]>
Commit | Line | Data |
---|---|---|
5dee515e | 1 | /* |
bbc27441 | 2 | * Copyright (C) 1996-2014 The Squid Software Foundation and contributors |
5dee515e | 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. | |
5dee515e | 7 | */ |
8 | ||
b0dd28ba | 9 | #ifndef SQUID_ACLPROTOCOL_H |
10 | #define SQUID_ACLPROTOCOL_H | |
0c3d3f65 | 11 | |
127dce76 | 12 | #include "acl/Strategised.h" |
602d9612 | 13 | #include "acl/Strategy.h" |
0c3d3f65 | 14 | #include "anyp/ProtocolType.h" |
5dee515e | 15 | |
0c3d3f65 | 16 | class ACLProtocolStrategy : public ACLStrategy<AnyP::ProtocolType> |
62e76326 | 17 | { |
18 | ||
19 | public: | |
33810b1d | 20 | virtual int match (ACLData<MatchType> * &, ACLFilledChecklist *, ACLFlags &); |
b0dd28ba | 21 | virtual bool requiresRequest() const {return true;} |
22 | ||
23 | static ACLProtocolStrategy *Instance(); | |
24 | /* Not implemented to prevent copies of the instance. */ | |
25 | /* Not private to prevent brain dead g+++ warnings about | |
26 | * private constructors with no friends */ | |
27 | ACLProtocolStrategy(ACLProtocolStrategy const &); | |
62e76326 | 28 | |
b0dd28ba | 29 | private: |
30 | static ACLProtocolStrategy Instance_; | |
26ac0430 | 31 | ACLProtocolStrategy() {} |
b0dd28ba | 32 | |
33 | ACLProtocolStrategy&operator=(ACLProtocolStrategy const &); | |
34 | }; | |
35 | ||
36 | class ACLProtocol | |
37 | { | |
62e76326 | 38 | |
b0dd28ba | 39 | private: |
40 | static ACL::Prototype RegistryProtoype; | |
0c3d3f65 | 41 | static ACLStrategised<AnyP::ProtocolType> RegistryEntry_; |
b0dd28ba | 42 | }; |
5dee515e | 43 | |
b0dd28ba | 44 | #endif /* SQUID_ACLPROTOCOL_H */ |