9#ifndef SQUID_SRC_BODYPIPE_H
10#define SQUID_SRC_BODYPIPE_H
139 const char *
status()
const;
#define RefCountable
The locking interface for use on Reference-Counted classes.
virtual void noteBodyProductionEnded(RefCount< BodyPipe > bp)=0
CbcPointer< BodyConsumer > Pointer
void stopConsumingFrom(RefCount< BodyPipe > &)
virtual void noteMoreBodyDataAvailable(RefCount< BodyPipe > bp)=0
virtual void noteBodyProducerAborted(RefCount< BodyPipe > bp)=0
const size_t checkedOutSize
BodyPipeCheckout & operator=(const BodyPipeCheckout &)
bool stillConsuming(const Consumer::Pointer &consumer) const
void scheduleBodyEndNotification()
void checkIn(Checkout &checkout)
void scheduleBodyDataNotification()
uint64_t producedSize() const
void expectNoConsumption()
there will be no more setConsumer() calls
size_t putMoreData(const char *buf, size_t size)
BodyPipeCheckout Checkout
size_t getMoreData(MemBuf &buf)
const MemBuf & buf() const
bool needsMoreData() const
void clearProducer(bool atEof)
static constexpr size_t MaxCapacity
void postConsume(size_t size)
bool bodySizeKnown() const
bool mustAutoConsume
keep theBuf empty when producing without consumer
bool abortedConsumption
called BodyProducer::noteBodyConsumerAborted
uint64_t unproducedSize() const
void setBodySize(uint64_t aSize)
void consume(size_t size)
uint64_t consumedSize() const
Producer::Pointer theProducer
bool setConsumerIfNotLate(const Consumer::Pointer &aConsumer)
void expectProductionEndAfter(uint64_t extraSize)
sets or checks body size
const char * status() const
void postAppend(size_t size)
bool stillProducing(const Producer::Pointer &producer) const
void startAutoConsumptionIfNeeded()
RefCount< BodyPipe > Pointer
bool productionEnded() const
bool mayNeedMoreData() const
uint64_t bodySize() const
void enableAutoConsumption()
start or continue consuming when producing without consumer
bool expectMoreAfter(uint64_t offset) const
void undoCheckOut(Checkout &checkout)
Consumer::Pointer theConsumer
CbcPointer< BodyProducer > Pointer
virtual void noteMoreBodySpaceAvailable(RefCount< BodyPipe > bp)=0
virtual void noteBodyConsumerAborted(RefCount< BodyPipe > bp)=0
void stopProducingFor(RefCount< BodyPipe > &, bool atEof)