Sequence.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 1996-2019 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 /* DEBUG: section 86 ESI processing */
10 
11 #ifndef SQUID_ESISEQUENCE_H
12 #define SQUID_ESISEQUENCE_H
13 
14 #include "esi/Element.h"
15 #include "mem/forward.h"
16 
17 /* esiSequence */
18 
19 class esiSequence : public ESIElement
20 {
22 
23 public:
24  esiSequence(esiTreeParentPtr, bool = false);
25  ~esiSequence();
26 
31  bool mayFail () const;
32  void wontFail();
33  void fail(ESIElement *, char const *anError = NULL);
34  void makeCachableElements(esiSequence const &old);
35  Pointer makeCacheable() const;
36  void makeUsableElements(esiSequence const &old, ESIVarState &);
38 
39  Esi::Elements elements; /* unprocessed or rendered nodes */
41 
42  struct {
43  int dovars:1; /* for esiVar */
44  } flags;
45  void finish();
46 
47 protected:
48  esiSequence(esiSequence const &);
50 
51 private:
52  int elementIndex (ESIElement::Pointer anElement) const;
53  bool mayFail_;
54  bool failed;
55  esiProcessResult_t processOne(int, size_t);
57  bool processing;
60  size_t nextElementToProcess() const;
61  void nextElementToProcess(size_t const &);
62  bool finishedProcessing() const;
63  void processStep(int dovars);
64 };
65 
66 #endif /* SQUID_ESISEQUENCE_H */
67 
Esi::Elements elements
Definition: Sequence.h:39
size_t nextElementToProcess_
Definition: Sequence.h:59
void finish()
Definition: Sequence.cc:104
Pointer makeCacheable() const
Definition: Sequence.cc:358
void render(ESISegment::Pointer)
Definition: Sequence.cc:82
bool processing
Definition: Sequence.h:57
esiProcessResult_t
Definition: Element.h:18
struct esiSequence::@66 flags
esiSequence(esiTreeParentPtr, bool=false)
Definition: Sequence.cc:33
bool mayFail() const
Definition: Sequence.cc:66
bool mayFail_
Definition: Sequence.h:53
void makeUsableElements(esiSequence const &old, ESIVarState &)
Definition: Sequence.cc:347
std::vector< ESIElement::Pointer > Elements
an ordered set of ESI elements
Definition: Element.h:92
Pointer makeUsable(esiTreeParentPtr, ESIVarState &) const
Definition: Sequence.cc:377
esiProcessResult_t processOne(int, size_t)
Definition: Sequence.cc:200
~esiSequence()
Definition: Sequence.cc:27
bool addElement(ESIElement::Pointer)
Definition: Sequence.cc:148
void provideData(ESISegment::Pointer, ESIElement *)
Definition: Sequence.cc:112
void wontFail()
Definition: Sequence.cc:75
MEMPROXY_CLASS(esiSequence)
void processStep(int dovars)
Definition: Sequence.cc:187
int dovars
Definition: Sequence.h:43
int elementIndex(ESIElement::Pointer anElement) const
Definition: Sequence.cc:177
size_t nextElementToProcess() const
Definition: Sequence.cc:48
void makeCachableElements(esiSequence const &old)
Definition: Sequence.cc:336
void fail(ESIElement *, char const *anError=NULL)
Definition: Sequence.cc:307
esiProcessResult_t processingResult
Definition: Sequence.h:58
bool const provideIncrementalData
Definition: Sequence.h:56
esiProcessResult_t process(int dovars)
Definition: Sequence.cc:238
size_t processedcount
Definition: Sequence.h:40
bool finishedProcessing() const
Definition: Sequence.cc:60
esiTreeParentPtr parent
Definition: Sequence.h:49
#define NULL
Definition: types.h:166
bool failed
Definition: Sequence.h:54

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors