|
Squid Web Cache master
|
#include <AsyncCallList.h>
Public Member Functions | |
| AsyncCallList ()=default | |
| AsyncCallList (const AsyncCallList &)=delete | |
| AsyncCallList & | operator= (const AsyncCallList &)=delete |
| void | add (const AsyncCallPointer &) |
| stores the given async call | |
| AsyncCallPointer | extract () |
| size_t | size () const |
| the number of currently stored calls | |
Private Attributes | |
| AsyncCallPointer | head |
| the earliest still-stored call (or nil) | |
| AsyncCallPointer | tail |
| the latest still-stored call (or nil) | |
| size_t | length = 0 |
An efficient (but intrusive) AsyncCall storage preserving FIFO order. A given AsyncCall object may reside in at most one such storage.
Definition at line 17 of file AsyncCallList.h.
|
default |
|
delete |
| void AsyncCallList::add | ( | const AsyncCallPointer & | call | ) |
Definition at line 15 of file AsyncCallList.cc.
References Assure, head, length, AsyncCall::Next(), AsyncCall::setNext(), and tail.
Referenced by DelayedAsyncCalls::delay(), and AsyncCallQueue::schedule().
| AsyncCall::Pointer AsyncCallList::extract | ( | ) |
removes the earliest add()-ed call that is still stored (if any)
| nil | means the list stored no calls at extract() time |
Definition at line 33 of file AsyncCallList.cc.
References Assure, head, length, AsyncCall::Next(), AsyncCall::setNext(), and tail.
Referenced by AsyncCallQueue::fire(), and DelayedAsyncCalls::schedule().
|
delete |
|
inline |
Definition at line 34 of file AsyncCallList.h.
References length.
Referenced by DelayedAsyncCalls::delay(), and AsyncCallQueue::fire().
|
private |
Definition at line 37 of file AsyncCallList.h.
|
private |
maximum number of elements in array
Definition at line 39 of file AsyncCallList.h.
|
private |
Definition at line 38 of file AsyncCallList.h.