
The Fetch spec unfortunately will cause a name clash between the Request concept and the Request JS object - both cannot live in the Web::Fetch namespace, and WrapperGenerator generally assumes `Web::<Name>` for things living in the `<Name>/` subdirectory, so let's instead move infra code into its own namespace - it already sits in a (sub-)subdirectory anyway.
18 lines
420 B
C++
18 lines
420 B
C++
/*
|
|
* Copyright (c) 2022, Linus Groh <linusg@serenityos.org>
|
|
*
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include <AK/Forward.h>
|
|
|
|
namespace Web::Fetch::Infrastructure {
|
|
|
|
[[nodiscard]] bool is_method(ReadonlyBytes);
|
|
[[nodiscard]] bool is_cors_safelisted_method(ReadonlyBytes);
|
|
[[nodiscard]] bool is_forbidden_method(ReadonlyBytes);
|
|
[[nodiscard]] ErrorOr<ByteBuffer> normalize_method(ReadonlyBytes);
|
|
|
|
}
|