summaryrefslogtreecommitdiff
path: root/src/ClientConnection.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/ClientConnection.h')
-rw-r--r--src/ClientConnection.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/ClientConnection.h b/src/ClientConnection.h
new file mode 100644
index 0000000..6fdf99e
--- /dev/null
+++ b/src/ClientConnection.h
@@ -0,0 +1,16 @@
+#pragma once
+
+#include "HttpResponse.h"
+
+class ClientConnection {
+public:
+ ClientConnection(int socket);
+
+ void dump_request_data();
+
+ bool send(const HttpResponse&, const char*);
+ void close();
+private:
+ int m_socket_fd;
+ bool m_is_open { true };
+};