Bug 1941046 - Part 4: Send a callback request for impression and clicks of MARS Top...
[gecko.git] / dom / fetch / FetchIPCTypes.h
blobde978ce8c60e2a7c6ca7743fdf33bedd571b334c
1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
3 /* This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 #ifndef mozilla_dom_fetch_IPCUtils_h
8 #define mozilla_dom_fetch_IPCUtils_h
10 #include "ipc/EnumSerializer.h"
12 #include "mozilla/dom/BindingIPCUtils.h"
13 #include "mozilla/dom/HeadersBinding.h"
14 #include "mozilla/dom/RequestBinding.h"
15 #include "mozilla/dom/ResponseBinding.h"
16 #include "mozilla/dom/FetchDriver.h"
18 namespace IPC {
19 template <>
20 struct ParamTraits<mozilla::dom::HeadersGuardEnum>
21 : public mozilla::dom::WebIDLEnumSerializer<
22 mozilla::dom::HeadersGuardEnum> {};
23 template <>
24 struct ParamTraits<mozilla::dom::ReferrerPolicy>
25 : public mozilla::dom::WebIDLEnumSerializer<mozilla::dom::ReferrerPolicy> {
27 template <>
28 struct ParamTraits<mozilla::dom::RequestMode>
29 : public mozilla::dom::WebIDLEnumSerializer<mozilla::dom::RequestMode> {};
30 template <>
31 struct ParamTraits<mozilla::dom::RequestCredentials>
32 : public mozilla::dom::WebIDLEnumSerializer<
33 mozilla::dom::RequestCredentials> {};
34 template <>
35 struct ParamTraits<mozilla::dom::RequestCache>
36 : public mozilla::dom::WebIDLEnumSerializer<mozilla::dom::RequestCache> {};
37 template <>
38 struct ParamTraits<mozilla::dom::RequestRedirect>
39 : public mozilla::dom::WebIDLEnumSerializer<mozilla::dom::RequestRedirect> {
41 template <>
42 struct ParamTraits<mozilla::dom::RequestPriority>
43 : public mozilla::dom::WebIDLEnumSerializer<mozilla::dom::RequestPriority> {
45 template <>
46 struct ParamTraits<mozilla::dom::ResponseType>
47 : public mozilla::dom::WebIDLEnumSerializer<mozilla::dom::ResponseType> {};
49 template <>
50 struct ParamTraits<mozilla::dom::FetchDriverObserver::EndReason>
51 : public ContiguousEnumSerializerInclusive<
52 mozilla::dom::FetchDriverObserver::EndReason,
53 mozilla::dom::FetchDriverObserver::eAborted,
54 mozilla::dom::FetchDriverObserver::eByNetworking> {};
55 } // namespace IPC
57 #endif // mozilla_dom_fetch_IPCUtils_h