]> git.ipfire.org Git - thirdparty/squid.git/blobdiff - src/HttpControlMsg.h
Source Format Enforcement (#763)
[thirdparty/squid.git] / src / HttpControlMsg.h
index fb3fa8e600267f97efd00007887ff8153876033b..55a612d168553f0061286050ae2c4103e122e5c0 100644 (file)
@@ -1,9 +1,18 @@
+/*
+ * Copyright (C) 1996-2021 The Squid Software Foundation and contributors
+ *
+ * Squid software is distributed under GPLv2+ license and includes
+ * contributions from numerous individuals and organizations.
+ * Please see the COPYING and CONTRIBUTORS files for details.
+ */
+
 #ifndef SQUID_HTTP_CONTROL_MSG_H
 #define SQUID_HTTP_CONTROL_MSG_H
 
 #include "base/AsyncCall.h"
 #include "HttpReply.h"
 
+class CommIoCbParams;
 class HttpControlMsg;
 
 /*
@@ -23,6 +32,14 @@ public:
 
     /// called to send the 1xx message and notify the Source
     virtual void sendControlMsg(HttpControlMsg msg) = 0;
+
+    virtual void doneWithControlMsg();
+
+    /// callback to handle Comm::Write completion
+    void wroteControlMsg(const CommIoCbParams &);
+
+    /// Call to schedule when the control msg has been sent
+    AsyncCall::Pointer cbControlMsgSent;
 };
 
 /// bundles HTTP 1xx reply and the "successfully forwarded" callback
@@ -32,7 +49,7 @@ public:
     typedef AsyncCall::Pointer Callback;
 
     HttpControlMsg(const HttpReply::Pointer &aReply, const Callback &aCallback):
-            reply(aReply), cbSuccess(aCallback) {}
+        reply(aReply), cbSuccess(aCallback) {}
 
 public:
     HttpReply::Pointer reply; ///< the 1xx message being forwarded
@@ -50,3 +67,4 @@ operator <<(std::ostream &os, const HttpControlMsg &msg)
 }
 
 #endif /* SQUID_HTTP_CONTROL_MSG_H */
+