Random.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 1996-2017 The Squid Software Foundation and contributors
3  *
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.
7  */
8 
9 #ifndef SQUID_ACL_RANDOM_H
10 #define SQUID_ACL_RANDOM_H
11 
12 #include "acl/Acl.h"
13 
14 class ACLRandom : public ACL
15 {
17 
18 public:
19  ACLRandom(char const *);
20  ACLRandom(ACLRandom const &);
21  ~ACLRandom();
22  ACLRandom&operator=(ACLRandom const &);
23 
24  virtual ACL *clone()const;
25  virtual char const *typeString() const;
26  virtual void parse();
27  virtual int match(ACLChecklist *checklist);
28  virtual SBufList dump() const;
29  virtual bool empty () const;
30  virtual bool valid() const;
31 
32 protected:
33  double data; // value to be exceeded before this ACL will match
34  char pattern[256]; // pattern from config file. Used to generate 'data'
35  char const *class_;
36 };
37 
38 #endif /* SQUID_ACL_RANDOM_H */
39 
ACLRandom & operator=(ACLRandom const &)
Definition: Acl.h:39
virtual ACL * clone() const
Definition: Random.cc:21
char pattern[256]
Definition: Random.h:34
~ACLRandom()
Definition: Random.cc:36
virtual char const * typeString() const
Definition: Random.cc:40
virtual bool valid() const
Definition: Random.cc:52
virtual int match(ACLChecklist *checklist)
Matches the actual data in checklist against this ACL.
Definition: Random.cc:104
virtual bool empty() const
Definition: Random.cc:46
virtual void parse()
parses node represenation in squid.conf; dies on failures
Definition: Random.cc:61
std::list< SBuf > SBufList
Definition: forward.h:26
MEMPROXY_CLASS(ACLRandom)
ACLRandom(char const *)
Definition: Random.cc:26
double data
Definition: Random.h:33
virtual SBufList dump() const
Definition: Random.cc:120
char const * class_
Definition: Random.h:35

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors