]>
git.ipfire.org Git - thirdparty/squid.git/blob - src/comm/Write.h
1 #ifndef _SQUID_COMM_IOWRITE_H
2 #define _SQUID_COMM_IOWRITE_H
4 #include "base/AsyncCall.h"
5 #include "comm/forward.h"
13 * Queue a write. callback is scheduled when the write
14 * completes, on error, or on file descriptor close.
16 * free_func is used to free the passed buffer when the write has completed.
18 void Write(const Comm::ConnectionPointer
&conn
, const char *buf
, int size
, AsyncCall::Pointer
&callback
, FREE
*free_func
);
21 * Queue a write. callback is scheduled when the write
22 * completes, on error, or on file descriptor close.
24 void Write(const Comm::ConnectionPointer
&conn
, MemBuf
*mb
, AsyncCall::Pointer
&callback
);
26 /// Cancel the write pending on FD. No action if none pending.
27 void WriteCancel(const Comm::ConnectionPointer
&conn
, const char *reason
);
29 // callback handler to process an FD which is available for writing.
30 extern PF HandleWrite
;
34 #endif /* _SQUID_COMM_IOWRITE_H */