Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1060)

Unified Diff: third_party/WebKit/public/platform/modules/fetch/fetch_api_request.mojom

Issue 2762303002: Enable transmitting Fetch Requests over Mojo (Closed)
Patch Set: Enable transmitting Fetch Requests over Mojo Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/public/platform/modules/fetch/OWNERS ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/public/platform/modules/fetch/fetch_api_request.mojom
diff --git a/third_party/WebKit/public/platform/modules/fetch/fetch_api_request.mojom b/third_party/WebKit/public/platform/modules/fetch/fetch_api_request.mojom
new file mode 100644
index 0000000000000000000000000000000000000000..c10c8662c8107b341a86b88d00f1a548c25e02e9
--- /dev/null
+++ b/third_party/WebKit/public/platform/modules/fetch/fetch_api_request.mojom
@@ -0,0 +1,105 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+module blink.mojom;
+
+import "third_party/WebKit/public/platform/referrer.mojom";
+import "url/mojo/url.mojom";
+
+// The mode associated with a request.
+// https://fetch.spec.whatwg.org/#concept-request-mode
+enum FetchRequestMode {
+ SAME_ORIGIN,
+ NO_CORS,
+ CORS,
+ CORS_WITH_FORCED_PREFLIGHT,
+ NAVIGATE,
+};
+
+// Type of the context associated with a request.
+enum RequestContextType {
+ UNSPECIFIED,
+ AUDIO,
+ BEACON,
+ CSP_REPORT,
+ DOWNLOAD,
+ EMBED,
+ EVENT_SOURCE,
+ FAVICON,
+ FETCH,
+ FONT,
+ FORM,
+ FRAME,
+ HYPERLINK,
+ IFRAME,
+ IMAGE,
+ IMAGE_SET,
+ IMPORT,
+ INTERNAL,
+ LOCATION,
+ MANIFEST,
+ OBJECT,
+ PING,
+ PLUGIN,
+ PREFETCH,
+ SCRIPT,
+ SERVICE_WORKER,
+ SHARED_WORKER,
+ SUBRESOURCE,
+ STYLE,
+ TRACK,
+ VIDEO,
+ WORKER,
+ XML_HTTP_REQUEST,
+ XSLT,
+};
+
+// Frame type of the context associated with a request.
+enum RequestContextFrameType {
+ AUXILIARY,
+ NESTED,
+ NONE,
+ TOP_LEVEL,
+};
+
+// Credentials mode indicating which credentials should be included with a
+// request.
+enum FetchCredentialsMode {
+ OMIT,
+ SAME_ORIGIN,
+ INCLUDE,
+ PASSWORD,
+};
+
+// The redirect mode indicating how redirects should be handled.
+// https://fetch.spec.whatwg.org/#concept-request-redirect-mode
+enum FetchRedirectMode {
+ FOLLOW,
+ ERROR_MODE,
+ MANUAL,
+};
+
+// Whether this is a regular fetch, or a foreign fetch request.
+enum ServiceWorkerFetchType {
+ FETCH,
+ FOREIGN_FETCH,
+};
+
+struct FetchAPIRequest {
+ FetchRequestMode mode;
+ bool is_main_resource_load;
+ RequestContextType request_context_type;
+ RequestContextFrameType frame_type;
+ url.mojom.Url url;
+ string method;
+ map<string, string> headers;
+ string? blob_uuid;
+ uint64 blob_size;
+ Referrer referrer;
+ FetchCredentialsMode credentials_mode;
+ FetchRedirectMode redirect_mode;
+ string? client_id;
+ bool is_reload;
+ ServiceWorkerFetchType fetch_type;
+};
« no previous file with comments | « third_party/WebKit/public/platform/modules/fetch/OWNERS ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698