Enums.h 1.4 KB

123456789101112131415161718192021222324252627282930
  1. /*
  2. * Copyright (c) 2022, Linus Groh <linusg@serenityos.org>
  3. *
  4. * SPDX-License-Identifier: BSD-2-Clause
  5. */
  6. #pragma once
  7. #include <AK/Forward.h>
  8. #include <LibWeb/Fetch/Infrastructure/HTTP/Requests.h>
  9. #include <LibWeb/Fetch/Infrastructure/HTTP/Responses.h>
  10. #include <LibWeb/Forward.h>
  11. namespace Web::Fetch {
  12. [[nodiscard]] ReferrerPolicy::ReferrerPolicy from_bindings_enum(Bindings::ReferrerPolicy);
  13. [[nodiscard]] Infrastructure::Request::Mode from_bindings_enum(Bindings::RequestMode);
  14. [[nodiscard]] Infrastructure::Request::CredentialsMode from_bindings_enum(Bindings::RequestCredentials);
  15. [[nodiscard]] Infrastructure::Request::CacheMode from_bindings_enum(Bindings::RequestCache);
  16. [[nodiscard]] Infrastructure::Request::RedirectMode from_bindings_enum(Bindings::RequestRedirect);
  17. [[nodiscard]] Bindings::ReferrerPolicy to_bindings_enum(ReferrerPolicy::ReferrerPolicy);
  18. [[nodiscard]] Bindings::RequestDestination to_bindings_enum(Optional<Infrastructure::Request::Destination> const&);
  19. [[nodiscard]] Bindings::RequestMode to_bindings_enum(Infrastructure::Request::Mode);
  20. [[nodiscard]] Bindings::RequestCredentials to_bindings_enum(Infrastructure::Request::CredentialsMode);
  21. [[nodiscard]] Bindings::RequestCache to_bindings_enum(Infrastructure::Request::CacheMode);
  22. [[nodiscard]] Bindings::RequestRedirect to_bindings_enum(Infrastructure::Request::RedirectMode);
  23. [[nodiscard]] Bindings::ResponseType to_bindings_enum(Infrastructure::Response::Type);
  24. }