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

Side by Side Diff: chrome/common/extensions/docs/experimental.webRequest.html

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: Created 8 years, 8 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 <!DOCTYPE html><!-- This page is a placeholder for generated extensions api doc. Note: 1 <!DOCTYPE html><!-- This page is a placeholder for generated extensions api doc. Note:
2 1) The <head> information in this page is significant, should be uniform 2 1) The <head> information in this page is significant, should be uniform
3 across api docs and should be edited only with knowledge of the 3 across api docs and should be edited only with knowledge of the
4 templating mechanism. 4 templating mechanism.
5 3) All <body>.innerHTML is genereated as an rendering step. If viewed in a 5 3) All <body>.innerHTML is genereated as an rendering step. If viewed in a
6 browser, it will be re-generated from the template, json schema and 6 browser, it will be re-generated from the template, json schema and
7 authored overview content. 7 authored overview content.
8 4) The <body>.innerHTML is also generated by an offline step so that this 8 4) The <body>.innerHTML is also generated by an offline step so that this
9 page may easily be indexed by search engines. 9 page may easily be indexed by search engines.
10 --><html xmlns="http://www.w3.org/1999/xhtml"><head> 10 --><html xmlns="http://www.w3.org/1999/xhtml"><head>
11 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> 11 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
12 <link href="css/ApiRefStyles.css" rel="stylesheet" type="text/css"> 12 <link href="css/ApiRefStyles.css" rel="stylesheet" type="text/css">
13 <link href="css/print.css" rel="stylesheet" type="text/css" media="print"> 13 <link href="css/print.css" rel="stylesheet" type="text/css" media="print">
14 <script type="text/javascript" src="../../../third_party/jstemplate/jstempla te_compiled.js"> 14 <script type="text/javascript" src="../../../third_party/jstemplate/jstempla te_compiled.js">
15 </script> 15 </script>
16 <script type="text/javascript" src="../../../../third_party/json_minify/mini fy-sans-regexp.js"> 16 <script type="text/javascript" src="../../../../third_party/json_minify/mini fy-sans-regexp.js">
17 </script> 17 </script>
18 <script type="text/javascript" src="js/api_page_generator.js"></script> 18 <script type="text/javascript" src="js/api_page_generator.js"></script>
19 <script type="text/javascript" src="js/bootstrap.js"></script> 19 <script type="text/javascript" src="js/bootstrap.js"></script>
20 <script type="text/javascript" src="js/sidebar.js"></script> 20 <script type="text/javascript" src="js/sidebar.js"></script>
21 <meta name="description" content="Documentation for the chrome.experimental.we bRequest module, which is part of the Google Chrome extension APIs."><title>exp erimental.webRequest - Google Chrome Extensions - Google Code</title></head> 21 <title>experimental.webRequest - Google Chrome Extensions - Google Code</title ></head>
22 <body> <div id="devModeWarning" class="displayModeWarning"> 22 <body> <div id="devModeWarning" class="displayModeWarning">
23 You are viewing extension docs in chrome via the 'file:' scheme: are you exp ecting to see local changes when you refresh? You'll need run chrome with --allo w-file-access-from-files. 23 You are viewing extension docs in chrome via the 'file:' scheme: are you exp ecting to see local changes when you refresh? You'll need run chrome with --allo w-file-access-from-files.
24 </div> 24 </div>
25 <div id="branchWarning" class="displayModeWarning"> 25 <div id="branchWarning" class="displayModeWarning">
26 <span>WARNING: This is the <span id="branchName">BETA</span> documentation. 26 <span>WARNING: This is the <span id="branchName">BETA</span> documentation.
27 It may not work with the stable release of Chrome.</span> 27 It may not work with the stable release of Chrome.</span>
28 <select id="branchChooser"> 28 <select id="branchChooser">
29 <option>Choose a different version... 29 <option>Choose a different version...
30 </option><option value="">Stable 30 </option><option value="">Stable
31 </option><option value="beta">Beta 31 </option><option value="beta">Beta
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after
181 </ul> 181 </ul>
182 </div> 182 </div>
183 <script> 183 <script>
184 initToggles(); 184 initToggles();
185 </script> 185 </script>
186 <div class="g-unit" id="gc-pagecontent"> 186 <div class="g-unit" id="gc-pagecontent">
187 <div id="pageTitle"> 187 <div id="pageTitle">
188 <h1 class="page_title">experimental.webRequest</h1> 188 <h1 class="page_title">experimental.webRequest</h1>
189 </div> 189 </div>
190 <!-- TABLE OF CONTENTS --> 190 <!-- TABLE OF CONTENTS -->
191 <div id="toc">
192 <h2>Contents</h2>
193 <ol>
194 <li>
195 <a href="#apiReference">API reference: chrome.experimental.webRe quest</a>
196 <ol>
197 <li>
198 <a href="#global-events">Events</a>
199 <ol>
200 <li>
201 <a href="#event-onRequest">onRequest</a>
202 </li>
203 </ol>
204 </li>
205 <li>
206 <a href="#types">Types</a>
207 <ol>
208 <li>
209 <a href="#type-RequestMatcher">RequestMatcher</a>
210 <ol>
211 </ol>
212 </li><li>
213 <a href="#type-CancelRequest">CancelRequest</a>
214 <ol>
215 </ol>
216 </li><li>
217 <a href="#type-RedirectRequest">RedirectRequest</a>
218 <ol>
219 </ol>
220 </li>
221 </ol>
222 </li>
223 </ol>
224 </li>
225 </ol>
226 </div>
227 <!-- /TABLE OF CONTENTS --> 191 <!-- /TABLE OF CONTENTS -->
228 <!-- Standard content lead-in for experimental API pages --> 192 <!-- Standard content lead-in for experimental API pages -->
229 <!-- Standard content lead-in for APIs that are not yet available on the 193 <!-- Standard content lead-in for APIs that are not yet available on the
230 stable channel. --> 194 stable channel. -->
231 <!-- STATIC CONTENT PLACEHOLDER --> 195 <!-- STATIC CONTENT PLACEHOLDER -->
232 <div id="static"><div id="pageData-name" class="pageData">experimental.w ebRequest</div> 196 <div id="static"><div id="pageData-name" class="pageData">experimental.w ebRequest</div>
233 <p> 197 <p>
234 The <code>WebRequest</code> API is no longer experimental; 198 The <code>WebRequest</code> API is no longer experimental;
235 it's supported! You can read all about it at its new home: 199 it's supported! You can read all about it at its new home:
236 </p> 200 </p>
237 <blockquote> 201 <blockquote>
238 <a href="webRequest.html">chrome.webRequest</a> 202 <a href="webRequest.html">chrome.webRequest</a>
239 </blockquote> 203 </blockquote>
240 <p> 204 <p>
241 What you see below are early outcomes of the plan to implement a declarative 205 What you see below are early outcomes of the plan to implement a declarative
242 version of the WebRequest API. Please ignore this until we give notice. 206 version of the WebRequest API. Please ignore this until we give notice.
243 </p> 207 </p>
244 </div> 208 </div>
245 <!-- API PAGE --> 209 <!-- API PAGE -->
246 <div class="apiPage"> 210 <!-- /apiPage -->
247 <a name="apiReference"></a>
248 <h2>API reference: chrome.experimental.webRequest</h2>
249 <!-- PROPERTIES -->
250 <!-- /apiGroup -->
251 <!-- METHODS -->
252 <!-- /apiGroup -->
253 <!-- EVENTS -->
254 <div id="eventsTemplate" class="apiGroup">
255 <a name="global-events"></a>
256 <h3>Events</h3>
257 <!-- iterates over all events -->
258 <div class="apiItem">
259 <a name="event-onRequest"></a>
260 <h4>onRequest</h4>
261 <div class="summary">
262 <!-- Note: intentionally longer 80 columns -->
263 <span class="subdued">chrome.experimental.webRequest.</span><spa n>onRequest</span><span class="subdued">.addListener</span>(function(<span></spa n>) <span class="subdued">{...}</span><span></span>);
264 </div>
265 <div class="description">
266 <!-- LISTENER PARAMETERS -->
267 <!-- EXTRA PARAMETERS -->
268 <!-- LISTENER RETURN VALUE -->
269 <dl>
270 </dl>
271 </div> <!-- /description -->
272 </div> <!-- /apiItem -->
273 </div> <!-- /apiGroup -->
274 <!-- TYPES -->
275 <div class="apiGroup">
276 <a name="types"></a>
277 <h3 id="types">Types</h3>
278 <!-- iterates over all types -->
279 <div class="apiItem">
280 <a name="type-RequestMatcher"></a>
281 <h4>RequestMatcher</h4>
282 <div>
283 <dt>
284 <em>
285 <!-- TYPE -->
286 <div style="display:inline">
287 (
288 <span id="typeTemplate">
289 <span>
290 <span>object</span>
291 </span>
292 </span>
293 )
294 </div>
295 </em>
296 </dt>
297 <dd>Matches network events by various criteria.</dd>
298 <!-- OBJECT PROPERTIES -->
299 <dd>
300 <dl>
301 <div>
302 <div>
303 <dt>
304 <var>url</var>
305 <em>
306 <!-- TYPE -->
307 <div style="display:inline">
308 (
309 <span class="optional">optional</span>
310 <span id="typeTemplate">
311 <span>
312 <a>UrlFilter</a>
313 </span>
314 </span>
315 )
316 </div>
317 </em>
318 </dt>
319 <dd>Matches if the condition of the UrlFilter are fulfilled for the UR L of the request.</dd>
320 <!-- OBJECT PROPERTIES -->
321 <!-- OBJECT METHODS -->
322 <!-- OBJECT EVENT FIELDS -->
323 <!-- FUNCTION PARAMETERS -->
324 </div>
325 </div><div>
326 <div>
327 <dt>
328 <var>resourceType</var>
329 <em>
330 <!-- TYPE -->
331 <div style="display:inline">
332 (
333 <span class="optional">optional</span>
334 <span id="typeTemplate">
335 <span>
336 <span>
337 array of <span><span>
338 <span>
339 <span>string</span>
340 <span>["main_frame", "sub_frame", "stylesheet", "script" , "image", "object", "xmlhttprequest", "other"]</span>
341 </span>
342 </span></span>
343 </span>
344 </span>
345 </span>
346 )
347 </div>
348 </em>
349 </dt>
350 <dd>Matches if the request type of a request is contained in the list. Requests that cannot match any of the types will be filtered out.</dd>
351 <!-- OBJECT PROPERTIES -->
352 <!-- OBJECT METHODS -->
353 <!-- OBJECT EVENT FIELDS -->
354 <!-- FUNCTION PARAMETERS -->
355 </div>
356 </div><div>
357 <div>
358 <dt>
359 <var>instanceType</var>
360 <em>
361 <!-- TYPE -->
362 <div style="display:inline">
363 (
364 <span class="enum">enumerated</span>
365 <span id="typeTemplate">
366 <span>
367 <span>string</span>
368 <span>["experimental.webRequest.RequestMatcher"]</span>
369 </span>
370 </span>
371 )
372 </div>
373 </em>
374 </dt>
375 <dd class="todo">
376 Undocumented.
377 </dd>
378 <!-- OBJECT PROPERTIES -->
379 <!-- OBJECT METHODS -->
380 <!-- OBJECT EVENT FIELDS -->
381 <!-- FUNCTION PARAMETERS -->
382 </div>
383 </div>
384 </dl>
385 </dd>
386 <!-- OBJECT METHODS -->
387 <!-- OBJECT EVENT FIELDS -->
388 <!-- FUNCTION PARAMETERS -->
389 </div>
390 </div><div class="apiItem">
391 <a name="type-CancelRequest"></a>
392 <h4>CancelRequest</h4>
393 <div>
394 <dt>
395 <em>
396 <!-- TYPE -->
397 <div style="display:inline">
398 (
399 <span id="typeTemplate">
400 <span>
401 <span>object</span>
402 </span>
403 </span>
404 )
405 </div>
406 </em>
407 </dt>
408 <dd>Declarative event action that cancels a network request.</dd>
409 <!-- OBJECT PROPERTIES -->
410 <dd>
411 <dl>
412 <div>
413 <div>
414 <dt>
415 <var>instanceType</var>
416 <em>
417 <!-- TYPE -->
418 <div style="display:inline">
419 (
420 <span class="enum">enumerated</span>
421 <span id="typeTemplate">
422 <span>
423 <span>string</span>
424 <span>["experimental.webRequest.CancelRequest"]</span>
425 </span>
426 </span>
427 )
428 </div>
429 </em>
430 </dt>
431 <dd class="todo">
432 Undocumented.
433 </dd>
434 <!-- OBJECT PROPERTIES -->
435 <!-- OBJECT METHODS -->
436 <!-- OBJECT EVENT FIELDS -->
437 <!-- FUNCTION PARAMETERS -->
438 </div>
439 </div>
440 </dl>
441 </dd>
442 <!-- OBJECT METHODS -->
443 <!-- OBJECT EVENT FIELDS -->
444 <!-- FUNCTION PARAMETERS -->
445 </div>
446 </div><div class="apiItem">
447 <a name="type-RedirectRequest"></a>
448 <h4>RedirectRequest</h4>
449 <div>
450 <dt>
451 <em>
452 <!-- TYPE -->
453 <div style="display:inline">
454 (
455 <span id="typeTemplate">
456 <span>
457 <span>object</span>
458 </span>
459 </span>
460 )
461 </div>
462 </em>
463 </dt>
464 <dd>Declarative event action that redirects a network request. (TODO: add destination)</dd>
465 <!-- OBJECT PROPERTIES -->
466 <dd>
467 <dl>
468 <div>
469 <div>
470 <dt>
471 <var>instanceType</var>
472 <em>
473 <!-- TYPE -->
474 <div style="display:inline">
475 (
476 <span class="enum">enumerated</span>
477 <span id="typeTemplate">
478 <span>
479 <span>string</span>
480 <span>["experimental.webRequest.RedirectRequest"]</span>
481 </span>
482 </span>
483 )
484 </div>
485 </em>
486 </dt>
487 <dd class="todo">
488 Undocumented.
489 </dd>
490 <!-- OBJECT PROPERTIES -->
491 <!-- OBJECT METHODS -->
492 <!-- OBJECT EVENT FIELDS -->
493 <!-- FUNCTION PARAMETERS -->
494 </div>
495 </div><div>
496 <div>
497 <dt>
498 <var>redirectUrl</var>
499 <em>
500 <!-- TYPE -->
501 <div style="display:inline">
502 (
503 <span id="typeTemplate">
504 <span>
505 <span>string</span>
506 </span>
507 </span>
508 )
509 </div>
510 </em>
511 </dt>
512 <dd>Destination to where the request is redirected.</dd>
513 <!-- OBJECT PROPERTIES -->
514 <!-- OBJECT METHODS -->
515 <!-- OBJECT EVENT FIELDS -->
516 <!-- FUNCTION PARAMETERS -->
517 </div>
518 </div>
519 </dl>
520 </dd>
521 <!-- OBJECT METHODS -->
522 <!-- OBJECT EVENT FIELDS -->
523 <!-- FUNCTION PARAMETERS -->
524 </div>
525 </div> <!-- /apiItem -->
526 </div> <!-- /apiGroup -->
527 </div> <!-- /apiPage -->
528 </div> <!-- /gc-pagecontent --> 211 </div> <!-- /gc-pagecontent -->
529 </div> <!-- /g-section --> 212 </div> <!-- /g-section -->
530 </div> <!-- /codesiteContent --> 213 </div> <!-- /codesiteContent -->
531 <div id="gc-footer" --=""> 214 <div id="gc-footer" --="">
532 <div class="text"> 215 <div class="text">
533 <p> 216 <p>
534 Except as otherwise <a href="http://code.google.com/policies.html#restrictions ">noted</a>, 217 Except as otherwise <a href="http://code.google.com/policies.html#restrictions ">noted</a>,
535 the content of this page is licensed under the <a rel="license" href="http://c reativecommons.org/licenses/by/3.0/">Creative Commons 218 the content of this page is licensed under the <a rel="license" href="http://c reativecommons.org/licenses/by/3.0/">Creative Commons
536 Attribution 3.0 License</a>, and code samples are licensed under the 219 Attribution 3.0 License</a>, and code samples are licensed under the
537 <a rel="license" href="http://code.google.com/google_bsd_license.html">BSD Lic ense</a>. 220 <a rel="license" href="http://code.google.com/google_bsd_license.html">BSD Lic ense</a>.
(...skipping 17 matching lines...) Expand all
555 _uff=0; 238 _uff=0;
556 urchinTracker(); 239 urchinTracker();
557 } 240 }
558 catch(e) {/* urchinTracker not available. */} 241 catch(e) {/* urchinTracker not available. */}
559 </script> 242 </script>
560 <!-- end analytics --> 243 <!-- end analytics -->
561 </div> 244 </div>
562 </div> <!-- /gc-footer --> 245 </div> <!-- /gc-footer -->
563 </div> <!-- /gc-container --> 246 </div> <!-- /gc-container -->
564 </body></html> 247 </body></html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698