diff options
Diffstat (limited to 'Userland/Services/RequestServer')
-rw-r--r-- | Userland/Services/RequestServer/GeminiProtocol.cpp | 2 | ||||
-rw-r--r-- | Userland/Services/RequestServer/GeminiProtocol.h | 2 | ||||
-rw-r--r-- | Userland/Services/RequestServer/HttpCommon.h | 2 | ||||
-rw-r--r-- | Userland/Services/RequestServer/HttpProtocol.cpp | 2 | ||||
-rw-r--r-- | Userland/Services/RequestServer/HttpProtocol.h | 2 | ||||
-rw-r--r-- | Userland/Services/RequestServer/HttpsProtocol.cpp | 2 | ||||
-rw-r--r-- | Userland/Services/RequestServer/HttpsProtocol.h | 2 | ||||
-rw-r--r-- | Userland/Services/RequestServer/Protocol.cpp | 4 | ||||
-rw-r--r-- | Userland/Services/RequestServer/Protocol.h | 8 | ||||
-rw-r--r-- | Userland/Services/RequestServer/Request.cpp | 2 | ||||
-rw-r--r-- | Userland/Services/RequestServer/Request.h | 6 |
11 files changed, 17 insertions, 17 deletions
diff --git a/Userland/Services/RequestServer/GeminiProtocol.cpp b/Userland/Services/RequestServer/GeminiProtocol.cpp index 2232e67635..befe40903d 100644 --- a/Userland/Services/RequestServer/GeminiProtocol.cpp +++ b/Userland/Services/RequestServer/GeminiProtocol.cpp @@ -17,7 +17,7 @@ GeminiProtocol::GeminiProtocol() { } -OwnPtr<Request> GeminiProtocol::start_request(ConnectionFromClient& client, const String&, const URL& url, const HashMap<String, String>&, ReadonlyBytes) +OwnPtr<Request> GeminiProtocol::start_request(ConnectionFromClient& client, String const&, const URL& url, HashMap<String, String> const&, ReadonlyBytes) { Gemini::GeminiRequest request; request.set_url(url); diff --git a/Userland/Services/RequestServer/GeminiProtocol.h b/Userland/Services/RequestServer/GeminiProtocol.h index 37d0e35091..4ecf29a070 100644 --- a/Userland/Services/RequestServer/GeminiProtocol.h +++ b/Userland/Services/RequestServer/GeminiProtocol.h @@ -15,7 +15,7 @@ public: GeminiProtocol(); virtual ~GeminiProtocol() override = default; - virtual OwnPtr<Request> start_request(ConnectionFromClient&, const String& method, const URL&, const HashMap<String, String>&, ReadonlyBytes body) override; + virtual OwnPtr<Request> start_request(ConnectionFromClient&, String const& method, const URL&, HashMap<String, String> const&, ReadonlyBytes body) override; }; } diff --git a/Userland/Services/RequestServer/HttpCommon.h b/Userland/Services/RequestServer/HttpCommon.h index f7bd86b9d5..7ea0a18573 100644 --- a/Userland/Services/RequestServer/HttpCommon.h +++ b/Userland/Services/RequestServer/HttpCommon.h @@ -61,7 +61,7 @@ void init(TSelf* self, TJob job) } template<typename TBadgedProtocol, typename TPipeResult> -OwnPtr<Request> start_request(TBadgedProtocol&& protocol, ConnectionFromClient& client, const String& method, const URL& url, const HashMap<String, String>& headers, ReadonlyBytes body, TPipeResult&& pipe_result) +OwnPtr<Request> start_request(TBadgedProtocol&& protocol, ConnectionFromClient& client, String const& method, const URL& url, HashMap<String, String> const& headers, ReadonlyBytes body, TPipeResult&& pipe_result) { using TJob = typename TBadgedProtocol::Type::JobType; using TRequest = typename TBadgedProtocol::Type::RequestType; diff --git a/Userland/Services/RequestServer/HttpProtocol.cpp b/Userland/Services/RequestServer/HttpProtocol.cpp index 4778547a97..fdfc4971d5 100644 --- a/Userland/Services/RequestServer/HttpProtocol.cpp +++ b/Userland/Services/RequestServer/HttpProtocol.cpp @@ -22,7 +22,7 @@ HttpProtocol::HttpProtocol() { } -OwnPtr<Request> HttpProtocol::start_request(ConnectionFromClient& client, const String& method, const URL& url, const HashMap<String, String>& headers, ReadonlyBytes body) +OwnPtr<Request> HttpProtocol::start_request(ConnectionFromClient& client, String const& method, const URL& url, HashMap<String, String> const& headers, ReadonlyBytes body) { return Detail::start_request(Badge<HttpProtocol> {}, client, method, url, headers, body, get_pipe_for_request()); } diff --git a/Userland/Services/RequestServer/HttpProtocol.h b/Userland/Services/RequestServer/HttpProtocol.h index cfedf92cfe..012e6bc033 100644 --- a/Userland/Services/RequestServer/HttpProtocol.h +++ b/Userland/Services/RequestServer/HttpProtocol.h @@ -27,7 +27,7 @@ public: HttpProtocol(); ~HttpProtocol() override = default; - virtual OwnPtr<Request> start_request(ConnectionFromClient&, const String& method, const URL&, const HashMap<String, String>& headers, ReadonlyBytes body) override; + virtual OwnPtr<Request> start_request(ConnectionFromClient&, String const& method, const URL&, HashMap<String, String> const& headers, ReadonlyBytes body) override; }; } diff --git a/Userland/Services/RequestServer/HttpsProtocol.cpp b/Userland/Services/RequestServer/HttpsProtocol.cpp index 5cd18ca74a..0580bff44b 100644 --- a/Userland/Services/RequestServer/HttpsProtocol.cpp +++ b/Userland/Services/RequestServer/HttpsProtocol.cpp @@ -22,7 +22,7 @@ HttpsProtocol::HttpsProtocol() { } -OwnPtr<Request> HttpsProtocol::start_request(ConnectionFromClient& client, const String& method, const URL& url, const HashMap<String, String>& headers, ReadonlyBytes body) +OwnPtr<Request> HttpsProtocol::start_request(ConnectionFromClient& client, String const& method, const URL& url, HashMap<String, String> const& headers, ReadonlyBytes body) { return Detail::start_request(Badge<HttpsProtocol> {}, client, method, url, headers, body, get_pipe_for_request()); } diff --git a/Userland/Services/RequestServer/HttpsProtocol.h b/Userland/Services/RequestServer/HttpsProtocol.h index 6c13cd76f2..c1083b684a 100644 --- a/Userland/Services/RequestServer/HttpsProtocol.h +++ b/Userland/Services/RequestServer/HttpsProtocol.h @@ -27,7 +27,7 @@ public: HttpsProtocol(); ~HttpsProtocol() override = default; - virtual OwnPtr<Request> start_request(ConnectionFromClient&, const String& method, const URL&, const HashMap<String, String>& headers, ReadonlyBytes body) override; + virtual OwnPtr<Request> start_request(ConnectionFromClient&, String const& method, const URL&, HashMap<String, String> const& headers, ReadonlyBytes body) override; }; } diff --git a/Userland/Services/RequestServer/Protocol.cpp b/Userland/Services/RequestServer/Protocol.cpp index c7b385b22d..f9f2fe1692 100644 --- a/Userland/Services/RequestServer/Protocol.cpp +++ b/Userland/Services/RequestServer/Protocol.cpp @@ -19,12 +19,12 @@ static HashMap<String, Protocol*>& all_protocols() return map; } -Protocol* Protocol::find_by_name(const String& name) +Protocol* Protocol::find_by_name(String const& name) { return all_protocols().get(name).value_or(nullptr); } -Protocol::Protocol(const String& name) +Protocol::Protocol(String const& name) { all_protocols().set(name, this); } diff --git a/Userland/Services/RequestServer/Protocol.h b/Userland/Services/RequestServer/Protocol.h index cd8a969c32..e0ab1493fc 100644 --- a/Userland/Services/RequestServer/Protocol.h +++ b/Userland/Services/RequestServer/Protocol.h @@ -16,13 +16,13 @@ class Protocol { public: virtual ~Protocol(); - const String& name() const { return m_name; } - virtual OwnPtr<Request> start_request(ConnectionFromClient&, const String& method, const URL&, const HashMap<String, String>& headers, ReadonlyBytes body) = 0; + String const& name() const { return m_name; } + virtual OwnPtr<Request> start_request(ConnectionFromClient&, String const& method, const URL&, HashMap<String, String> const& headers, ReadonlyBytes body) = 0; - static Protocol* find_by_name(const String&); + static Protocol* find_by_name(String const&); protected: - explicit Protocol(const String& name); + explicit Protocol(String const& name); struct Pipe { int read_fd { -1 }; int write_fd { -1 }; diff --git a/Userland/Services/RequestServer/Request.cpp b/Userland/Services/RequestServer/Request.cpp index f733115ee1..752a3c2b9a 100644 --- a/Userland/Services/RequestServer/Request.cpp +++ b/Userland/Services/RequestServer/Request.cpp @@ -24,7 +24,7 @@ void Request::stop() m_client.did_finish_request({}, *this, false); } -void Request::set_response_headers(const HashMap<String, String, CaseInsensitiveStringTraits>& response_headers) +void Request::set_response_headers(HashMap<String, String, CaseInsensitiveStringTraits> const& response_headers) { m_response_headers = response_headers; m_client.did_receive_headers({}, *this); diff --git a/Userland/Services/RequestServer/Request.h b/Userland/Services/RequestServer/Request.h index 8c16399463..562e8254c9 100644 --- a/Userland/Services/RequestServer/Request.h +++ b/Userland/Services/RequestServer/Request.h @@ -26,7 +26,7 @@ public: Optional<u32> status_code() const { return m_status_code; } Optional<u32> total_size() const { return m_total_size; } size_t downloaded_size() const { return m_downloaded_size; } - const HashMap<String, String, CaseInsensitiveStringTraits>& response_headers() const { return m_response_headers; } + HashMap<String, String, CaseInsensitiveStringTraits> const& response_headers() const { return m_response_headers; } void stop(); virtual void set_certificate(String, String); @@ -39,9 +39,9 @@ public: void did_progress(Optional<u32> total_size, u32 downloaded_size); void set_status_code(u32 status_code) { m_status_code = status_code; } void did_request_certificates(); - void set_response_headers(const HashMap<String, String, CaseInsensitiveStringTraits>&); + void set_response_headers(HashMap<String, String, CaseInsensitiveStringTraits> const&); void set_downloaded_size(size_t size) { m_downloaded_size = size; } - const Core::Stream::File& output_stream() const { return *m_output_stream; } + Core::Stream::File const& output_stream() const { return *m_output_stream; } protected: explicit Request(ConnectionFromClient&, NonnullOwnPtr<Core::Stream::File>&&); |