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

Side by Side Diff: chrome/common/extensions/api/declarativeWebRequest.json

Issue 10257006: Move Declarative Web Request API out of experimental and make it a feature (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merged with ToT Created 8 years, 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 [ 5 [
6 { 6 {
7 "namespace": "experimental.webRequest", 7 "namespace": "declarativeWebRequest",
8 "documentation_permissions_required": ["declarative", "declarativeWebRequest "],
8 "types": [ 9 "types": [
9 { 10 {
10 "id": "RequestMatcher", 11 "id": "RequestMatcher",
11 "type": "object", 12 "type": "object",
12 "description": "Matches network events by various criteria.", 13 "description": "Matches network events by various criteria.",
13 "properties": { 14 "properties": {
14 "url": { 15 "url": {
15 "$ref": "UrlFilter", 16 "$ref": "UrlFilter",
16 "description": "Matches if the condition of the UrlFilter are fulfil led for the URL of the request.", 17 "description": "Matches if the condition of the UrlFilter are fulfil led for the URL of the request.",
17 "optional": true 18 "optional": true
18 }, 19 },
19 "resourceType": { 20 "resourceType": {
20 "type": "array", 21 "type": "array",
21 "optional": true, 22 "optional": true,
22 "description": "Matches if the request type of a request is containe d in the list. Requests that cannot match any of the types will be filtered out. ", 23 "description": "Matches if the request type of a request is containe d in the list. Requests that cannot match any of the types will be filtered out. ",
23 "items": { "type": "string", "enum": ["main_frame", "sub_frame", "st ylesheet", "script", "image", "object", "xmlhttprequest", "other"] } 24 "items": { "type": "string", "enum": ["main_frame", "sub_frame", "st ylesheet", "script", "image", "object", "xmlhttprequest", "other"] }
24 }, 25 },
25 "instanceType": { "type": "string", "enum": ["experimental.webRequest. RequestMatcher"] } 26 "instanceType": { "type": "string", "enum": ["declarativeWebRequest.Re questMatcher"] }
26 } 27 }
27 }, 28 },
28 { 29 {
29 "id": "CancelRequest", 30 "id": "CancelRequest",
30 "description": "Declarative event action that cancels a network request. ", 31 "description": "Declarative event action that cancels a network request. ",
31 "type": "object", 32 "type": "object",
32 "properties": { 33 "properties": {
33 "instanceType": { "type": "string", "enum": ["experimental.webRequest. CancelRequest"] } 34 "instanceType": { "type": "string", "enum": ["declarativeWebRequest.Ca ncelRequest"] }
34 } 35 }
35 }, 36 },
36 { 37 {
37 "id": "RedirectRequest", 38 "id": "RedirectRequest",
38 "description": "Declarative event action that redirects a network reques t. (TODO: add destination)", 39 "description": "Declarative event action that redirects a network reques t. (TODO: add destination)",
39 "type": "object", 40 "type": "object",
40 "properties": { 41 "properties": {
41 "instanceType": { "type": "string", "enum": ["experimental.webRequest. RedirectRequest"] }, 42 "instanceType": { "type": "string", "enum": ["declarativeWebRequest.Re directRequest"] },
42 "redirectUrl": { "type": "string", "description": "Destination to wher e the request is redirected."} 43 "redirectUrl": { "type": "string", "description": "Destination to wher e the request is redirected."}
43 } 44 }
44 } 45 }
45 ], 46 ],
46 "functions": [ 47 "functions": [
47 ], 48 ],
48 "events": [ 49 "events": [
49 { 50 {
50 "name": "onRequest", 51 "name": "onRequest",
51 "options": { 52 "options": {
52 "supportsListeners": false, 53 "supportsListeners": false,
53 "supportsRules": true, 54 "supportsRules": true,
54 "conditions": ["RequestMatcher"], 55 "conditions": ["RequestMatcher"],
55 "actions": ["CancelRequest", "RedirectRequest"] 56 "actions": ["CancelRequest", "RedirectRequest"]
56 } 57 }
57 } 58 }
58 ] 59 ]
59 } 60 }
60 ] 61 ]
OLDNEW
« no previous file with comments | « chrome/common/extensions/api/declarative.json ('k') | chrome/common/extensions/api/experimental.declarative.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698