1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 03:07:44 +00:00

GHttp: Work on bringing this up.

This commit is contained in:
Andreas Kling 2019-04-07 19:35:07 +02:00
parent 8f30657390
commit 51b4d3fe5a
9 changed files with 93 additions and 16 deletions

View file

@ -2,6 +2,7 @@
#include <LibGUI/GNetworkJob.h>
#include <LibGUI/GHttpRequest.h>
#include <AK/HashMap.h>
class GTCPSocket;
@ -15,6 +16,16 @@ public:
virtual const char* class_name() const override { return "GHttpNetworkJob"; }
private:
enum class State {
InStatus,
InHeaders,
InBody,
Finished,
};
GHttpRequest m_request;
GTCPSocket* m_socket { nullptr };
State m_state { State::InStatus };
int m_code { -1 };
HashMap<String, String> m_headers;
};