• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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
3       across api docs and should be edited only with knowledge of the
4       templating mechanism.
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
7       authored overview content.
8    4) The <body>.innerHTML is also generated by an offline step so that this
9       page may easily be indexed by search engines.
10--><html xmlns="http://www.w3.org/1999/xhtml"><head>
11    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
12    <link href="css/ApiRefStyles.css" rel="stylesheet" type="text/css">
13    <link href="css/print.css" rel="stylesheet" type="text/css" media="print">
14    <script type="text/javascript" src="../../../third_party/jstemplate/jstemplate_compiled.js">
15    </script>
16    <script type="text/javascript" src="js/api_page_generator.js"></script>
17    <script type="text/javascript" src="js/bootstrap.js"></script>
18    <script type="text/javascript" src="js/sidebar.js"></script>
19  <title>experimental.webInspector.resources - Google Chrome Extensions - Google Code</title></head>
20  <body>  <div id="gc-container" class="labs">
21      <div id="devModeWarning">
22        You are viewing extension docs in chrome via the 'file:' scheme: are you expecting to see local changes when you refresh? You'll need run chrome with --allow-file-access-from-files.
23      </div>
24      <!-- SUBTEMPLATES: DO NOT MOVE FROM THIS LOCATION -->
25      <!-- In particular, sub-templates that recurse, must be used by allowing
26           jstemplate to make a copy of the template in this section which
27           are not operated on by way of the jsskip="true" -->
28      <div style="display:none">
29
30        <!-- VALUE -->
31        <div id="valueTemplate">
32          <dt>
33            <var>paramName</var>
34              <em>
35
36                <!-- TYPE -->
37                <div style="display:inline">
38                  (
39                    <span class="optional">optional</span>
40                    <span class="enum">enumerated</span>
41                    <span id="typeTemplate">
42                      <span>
43                        <a> Type</a>
44                      </span>
45                      <span>
46                        <span>
47                          array of <span><span></span></span>
48                        </span>
49                        <span>paramType</span>
50                        <span></span>
51                      </span>
52                    </span>
53                  )
54                </div>
55
56              </em>
57          </dt>
58          <dd class="todo">
59            Undocumented.
60          </dd>
61          <dd>
62            Description of this parameter from the json schema.
63          </dd>
64          <dd>
65            This parameter was added in version
66            <b><span></span></b>.
67            You must omit this parameter in earlier versions,
68            and you may omit it in any version.  If you require this
69            parameter, the manifest key
70            <a href="manifest.html#minimum_chrome_version">minimum_chrome_version</a>
71            can ensure that your extension won't be run in an earlier browser version.
72          </dd>
73
74          <!-- OBJECT PROPERTIES -->
75          <dd>
76            <dl>
77              <div>
78                <div>
79                </div>
80              </div>
81            </dl>
82          </dd>
83
84          <!-- OBJECT METHODS -->
85          <dd>
86            <div></div>
87          </dd>
88
89          <!-- OBJECT EVENT FIELDS -->
90          <dd>
91            <div></div>
92          </dd>
93
94          <!-- FUNCTION PARAMETERS -->
95          <dd>
96            <div></div>
97          </dd>
98
99        </div> <!-- /VALUE -->
100
101        <div id="functionParametersTemplate">
102          <h5>Parameters</h5>
103          <dl>
104            <div>
105              <div>
106              </div>
107            </div>
108          </dl>
109        </div>
110      </div> <!-- /SUBTEMPLATES -->
111
112  <a id="top"></a>
113    <div id="skipto">
114      <a href="#gc-pagecontent">Skip to page content</a>
115      <a href="#gc-toc">Skip to main navigation</a>
116    </div>
117    <!-- API HEADER -->
118    <table id="header" width="100%" cellspacing="0" border="0">
119      <tbody><tr>
120        <td valign="middle"><a href="http://code.google.com/"><img src="images/code_labs_logo.gif" height="43" width="161" alt="Google Code Labs" style="border:0; margin:0;"></a></td>
121        <td valign="middle" width="100%" style="padding-left:0.6em;">
122          <form action="http://www.google.com/cse" id="cse" style="margin-top:0.5em">
123            <div id="gsc-search-box">
124              <input type="hidden" name="cx" value="002967670403910741006:61_cvzfqtno">
125              <input type="hidden" name="ie" value="UTF-8">
126              <input type="text" name="q" value="" size="55">
127              <input class="gsc-search-button" type="submit" name="sa" value="Search">
128              <br>
129              <span class="greytext">e.g. "page action" or "tabs"</span>
130            </div>
131          </form>
132
133          <script type="text/javascript" src="http://www.google.com/jsapi"></script>
134          <script type="text/javascript">google.load("elements", "1", {packages: "transliteration"});</script>
135          <script type="text/javascript" src="http://www.google.com/coop/cse/t13n?form=cse&amp;t13n_langs=en"></script>
136          <script type="text/javascript" src="http://www.google.com/coop/cse/brand?form=cse&amp;lang=en"></script>
137        </td>
138      </tr>
139    </tbody></table>
140
141    <div id="codesiteContent" class="">
142
143      <a id="gc-topnav-anchor"></a>
144      <div id="gc-topnav">
145        <h1>Google Chrome Extensions (<a href="http://code.google.com/labs/">Labs</a>)</h1>
146        <ul id="home" class="gc-topnav-tabs">
147          <li id="home_link">
148            <a href="index.html" title="Google Chrome Extensions home page">Home</a>
149          </li>
150          <li id="docs_link">
151            <a href="docs.html" title="Official Google Chrome Extensions documentation">Docs</a>
152          </li>
153          <li id="faq_link">
154            <a href="faq.html" title="Answers to frequently asked questions about Google Chrome Extensions">FAQ</a>
155          </li>
156          <li id="samples_link">
157            <a href="samples.html" title="Sample extensions (with source code)">Samples</a>
158          </li>
159          <li id="group_link">
160            <a href="http://groups.google.com/a/chromium.org/group/chromium-extensions" title="Google Chrome Extensions developer forum">Group</a>
161          </li>
162        </ul>
163      </div> <!-- end gc-topnav -->
164
165    <div class="g-section g-tpl-170">
166      <!-- SIDENAV -->
167      <div class="g-unit g-first" id="gc-toc">
168        <ul>
169          <li><a href="getstarted.html">Getting Started</a></li>
170          <li><a href="overview.html">Overview</a></li>
171          <li><a href="whats_new.html">What's New?</a></li>
172          <li><h2><a href="devguide.html">Developer's Guide</a></h2>
173            <ul>
174              <li>Browser UI
175                <ul>
176                  <li><a href="browserAction.html">Browser Actions</a></li>
177                  <li><a href="contextMenus.html">Context Menus</a></li>
178                  <li><a href="notifications.html">Desktop Notifications</a></li>
179                  <li><a href="omnibox.html">Omnibox</a></li>
180                  <li><a href="options.html">Options Pages</a></li>
181                  <li><a href="override.html">Override Pages</a></li>
182                  <li><a href="pageAction.html">Page Actions</a></li>
183                </ul>
184              </li>
185              <li>Browser Interaction
186                <ul>
187                  <li><a href="bookmarks.html">Bookmarks</a></li>
188                  <li><a href="cookies.html">Cookies</a></li>
189                  <li><a href="events.html">Events</a></li>
190                  <li><a href="history.html">History</a></li>
191                  <li><a href="management.html">Management</a></li>
192                  <li><a href="tabs.html">Tabs</a></li>
193                  <li><a href="windows.html">Windows</a></li>
194                </ul>
195              </li>
196              <li>Implementation
197                <ul>
198                  <li><a href="a11y.html">Accessibility</a></li>
199                  <li><a href="background_pages.html">Background Pages</a></li>
200                  <li><a href="content_scripts.html">Content Scripts</a></li>
201                  <li><a href="xhr.html">Cross-Origin XHR</a></li>
202                  <li><a href="idle.html">Idle</a></li>
203                  <li><a href="i18n.html">Internationalization</a></li>
204                  <li><a href="messaging.html">Message Passing</a></li>
205                  <li><a href="npapi.html">NPAPI Plugins</a></li>
206                </ul>
207              </li>
208              <li>Finishing
209                <ul>
210                  <li><a href="hosting.html">Hosting</a></li>
211                  <li><a href="external_extensions.html">Other Deployment Options</a></li>
212                </ul>
213              </li>
214            </ul>
215          </li>
216          <li><h2><a href="apps.html">Packaged Apps</a></h2></li>
217          <li><h2><a href="tutorials.html">Tutorials</a></h2>
218            <ul>
219              <li><a href="tut_debugging.html">Debugging</a></li>
220              <li><a href="tut_analytics.html">Google Analytics</a></li>
221              <li><a href="tut_oauth.html">OAuth</a></li>
222            </ul>
223          </li>
224          <li><h2>Reference</h2>
225            <ul>
226              <li>Formats
227                <ul>
228                  <li><a href="manifest.html">Manifest Files</a></li>
229                  <li><a href="match_patterns.html">Match Patterns</a></li>
230                </ul>
231              </li>
232              <li><a href="permission_warnings.html">Permission Warnings</a></li>
233              <li><a href="api_index.html">chrome.* APIs</a></li>
234              <li><a href="api_other.html">Other APIs</a></li>
235            </ul>
236          </li>
237          <li><h2><a href="samples.html">Samples</a></h2></li>
238          <div class="line"> </div>
239          <li><h2>More</h2>
240            <ul>
241              <li><a href="http://code.google.com/chrome/webstore/docs/index.html">Chrome Web Store</a></li>
242              <li><a href="http://code.google.com/chrome/apps/docs/developers_guide.html">Hosted Apps</a></li>
243              <li><a href="themes.html">Themes</a></li>
244            </ul>
245          </li>
246        </ul>
247      </div>
248      <script>
249        initToggles();
250      </script>
251
252    <div class="g-unit" id="gc-pagecontent">
253      <div id="pageTitle">
254        <h1 class="page_title">experimental.webInspector.resources</h1>
255      </div>
256        <!-- TABLE OF CONTENTS -->
257        <div id="toc">
258          <h2>Contents</h2>
259          <ol>
260            <li>
261              <a href="#H2-0">Notes</a>
262              <ol>
263                <li style="display: none; ">
264                  <a>h3Name</a>
265                </li>
266              </ol>
267            </li><li>
268              <a href="#overview-examples">Examples</a>
269              <ol>
270                <li style="display: none; ">
271                  <a>h3Name</a>
272                </li>
273              </ol>
274            </li>
275              <li>
276                <a href="#apiReference">API reference: experimental.webInspector.resources</a>
277                <ol>
278                  <li style="display: none; ">
279                    <a href="#properties">Properties</a>
280                    <ol>
281                      <li>
282                        <a href="#property-anchor">propertyName</a>
283                      </li>
284                    </ol>
285                  </li>
286                  <li>
287                    <a href="#global-methods">Methods</a>
288                    <ol>
289                      <li>
290                        <a href="#method-getHAR">getHAR</a>
291                      </li>
292                    </ol>
293                  </li>
294                  <li>
295                    <a href="#global-events">Events</a>
296                    <ol>
297                      <li>
298                        <a href="#event-onFinished">onFinished</a>
299                      </li>
300                    </ol>
301                  </li>
302                  <li>
303                    <a href="#types">Types</a>
304                    <ol>
305                      <li>
306                        <a href="#type-Resource">Resource</a>
307                      </li>
308                    </ol>
309                  </li>
310                </ol>
311              </li>
312          </ol>
313        </div>
314        <!-- /TABLE OF CONTENTS -->
315
316        <!-- Standard content lead-in for experimental API pages -->
317        <p id="classSummary" style="display: none; ">
318          For information on how to use experimental APIs, see the <a href="experimental.html">chrome.experimental.* APIs</a> page.
319        </p>
320
321        <!-- STATIC CONTENT PLACEHOLDER -->
322        <div id="static"><!-- BEGIN AUTHORED CONTENT -->
323<p id="classSummary">
324Use the <code>experimental.webInspector.resources</code> module to retrieve the
325information about network resources displayed by DevTools' Network panel.
326</p><p>
327See <a href="experimental.webInspector.html">WebInspector API summary</a> for
328general introduction to using WebInspector API.
329</p>
330
331<a name="H2-0"></a><h2>Notes</h2>
332
333<p>
334Network resource information is represented in HTTP Archive format
335(<em>HAR</em>). The description of HAR is outside of scope of this document,
336please refer to
337<a href="http://groups.google.com/group/http-archive-specification/web/har-1-2-spec">
338HAR v1.2 Specification</a>.
339</p><p>
340In terms of HAR, the <code>webInspector.resources.getHAR()</code> method
341returns entire <em>HAR log</em>, while
342<code>webInspector.resources.onFinish</code> event provides <em>HAR entry</em>
343as an argument to the event callback.
344</p>
345<p>Note that resource content is not provided as part of HAR for efficieny
346reasons. You may call resource's <code>getContent()</code> method to retrieve
347content.
348</p><p>Some resources may be missing in the array of entries returned by <code>
349getHAR()</code> in case WebInspector was opened after the page was loaded —
350reload the page to get all resources. In general, the list of resources returned
351by <code>getHAR()</code> should match that displayed by the Network panel.
352</p><h2 id="overview-examples">Examples</h2>
353
354<p>The following code logs URLs of all images larger than 40KB as they are
355loaded:</p>
356
357<pre>experimental.webInspector.resources.onFinished.addListener(function(resource) {
358  if (resource.response.bodySize &gt; 40*1024)
359    webInspector.log("Large image: " + resource.request.url);
360});
361</pre>
362
363<!-- END AUTHORED CONTENT -->
364</div>
365
366        <!-- API PAGE -->
367        <div class="apiPage">
368        <a name="apiReference"></a>
369        <h2>API reference: experimental.webInspector.resources</h2>
370
371          <!-- PROPERTIES -->
372          <div class="apiGroup" style="display: none; ">
373            <a name="properties"></a>
374            <h3 id="properties">Properties</h3>
375
376            <div>
377              <a></a>
378              <h4>getLastError</h4>
379              <div class="summary">
380                <!-- Note: intentionally longer 80 columns -->
381                <span>chrome.extension</span><span>lastError</span>
382              </div>
383              <div>
384              </div>
385            </div>
386
387          </div> <!-- /apiGroup -->
388
389          <!-- METHODS -->
390          <div id="methodsTemplate" class="apiGroup">
391            <a name="global-methods"></a>
392            <h3>Methods</h3>
393
394            <!-- iterates over all functions -->
395            <div class="apiItem">
396              <a name="method-getHAR"></a> <!-- method-anchor -->
397              <h4>getHAR</h4>
398
399              <div class="summary"><span style="display: none; ">void</span>
400                  <!-- Note: intentionally longer 80 columns -->
401                  <span>experimental.webInspector.resources.getHAR</span>(<span class="null"><span style="display: none; ">, </span><span>function</span>
402                      <var><span>callback</span></var></span>)</div>
403
404              <div class="description">
405                <p class="todo" style="display: none; ">Undocumented.</p>
406                <p>Returns HAR archive that contains all known resource objects.</p>
407
408                <!-- PARAMETERS -->
409                <h4>Parameters</h4>
410                <dl>
411                  <div>
412                    <div>
413          <dt>
414            <var>callback</var>
415              <em>
416
417                <!-- TYPE -->
418                <div style="display:inline">
419                  (
420                    <span class="optional" style="display: none; ">optional</span>
421                    <span class="enum" style="display: none; ">enumerated</span>
422                    <span id="typeTemplate">
423                      <span style="display: none; ">
424                        <a> Type</a>
425                      </span>
426                      <span>
427                        <span style="display: none; ">
428                          array of <span><span></span></span>
429                        </span>
430                        <span>function</span>
431                        <span style="display: none; "></span>
432                      </span>
433                    </span>
434                  )
435                </div>
436
437              </em>
438          </dt>
439          <dd class="todo" style="display: none; ">
440            Undocumented.
441          </dd>
442          <dd>A function that is called upon request completion.</dd>
443          <dd style="display: none; ">
444            This parameter was added in version
445            <b><span></span></b>.
446            You must omit this parameter in earlier versions,
447            and you may omit it in any version.  If you require this
448            parameter, the manifest key
449            <a href="manifest.html#minimum_chrome_version">minimum_chrome_version</a>
450            can ensure that your extension won't be run in an earlier browser version.
451          </dd>
452
453          <!-- OBJECT PROPERTIES -->
454          <dd style="display: none; ">
455            <dl>
456              <div>
457                <div>
458                </div>
459              </div>
460            </dl>
461          </dd>
462
463          <!-- OBJECT METHODS -->
464          <dd style="display: none; ">
465            <div></div>
466          </dd>
467
468          <!-- OBJECT EVENT FIELDS -->
469          <dd style="display: none; ">
470            <div></div>
471          </dd>
472
473          <!-- FUNCTION PARAMETERS -->
474          <dd style="display: none; ">
475            <div></div>
476          </dd>
477
478        </div>
479                  </div>
480                </dl>
481
482                <!-- RETURNS -->
483                <h4 style="display: none; ">Returns</h4>
484                <dl>
485                  <div style="display: none; ">
486                    <div>
487                    </div>
488                  </div>
489                </dl>
490
491                <!-- CALLBACK -->
492                <div>
493                  <div>
494                  <h4>Callback function</h4>
495                  <p>
496                    The callback <em>parameter</em> should specify a function
497                    that looks like this:
498                  </p>
499                  <p style="display: none; ">
500                    If you specify the <em>callback</em> parameter, it should
501                    specify a function that looks like this:
502                  </p>
503
504                  <!-- Note: intentionally longer 80 columns -->
505                  <pre>function(<span>object har</span>) <span class="subdued">{...}</span>;</pre>
506                  <dl>
507                    <div>
508                      <div>
509          <dt>
510            <var>har</var>
511              <em>
512
513                <!-- TYPE -->
514                <div style="display:inline">
515                  (
516                    <span class="optional" style="display: none; ">optional</span>
517                    <span class="enum" style="display: none; ">enumerated</span>
518                    <span id="typeTemplate">
519                      <span style="display: none; ">
520                        <a> Type</a>
521                      </span>
522                      <span>
523                        <span style="display: none; ">
524                          array of <span><span></span></span>
525                        </span>
526                        <span>object</span>
527                        <span style="display: none; "></span>
528                      </span>
529                    </span>
530                  )
531                </div>
532
533              </em>
534          </dt>
535          <dd class="todo" style="display: none; ">
536            Undocumented.
537          </dd>
538          <dd>A HAR archieve. See HAR specification for details.</dd>
539          <dd style="display: none; ">
540            This parameter was added in version
541            <b><span></span></b>.
542            You must omit this parameter in earlier versions,
543            and you may omit it in any version.  If you require this
544            parameter, the manifest key
545            <a href="manifest.html#minimum_chrome_version">minimum_chrome_version</a>
546            can ensure that your extension won't be run in an earlier browser version.
547          </dd>
548
549          <!-- OBJECT PROPERTIES -->
550          <dd style="display: none; ">
551            <dl>
552              <div>
553                <div>
554                </div>
555              </div>
556            </dl>
557          </dd>
558
559          <!-- OBJECT METHODS -->
560          <dd style="display: none; ">
561            <div></div>
562          </dd>
563
564          <!-- OBJECT EVENT FIELDS -->
565          <dd style="display: none; ">
566            <div></div>
567          </dd>
568
569          <!-- FUNCTION PARAMETERS -->
570          <dd style="display: none; ">
571            <div></div>
572          </dd>
573
574        </div>
575                    </div>
576                  </dl>
577                  </div>
578                </div>
579
580                <!-- MIN_VERSION -->
581                <p style="display: none; ">
582                  This function was added in version <b><span></span></b>.
583                  If you require this function, the manifest key
584                  <a href="manifest.html#minimum_chrome_version">minimum_chrome_version</a>
585                  can ensure that your extension won't be run in an earlier browser version.
586                </p>
587              </div> <!-- /description -->
588
589            </div>  <!-- /apiItem -->
590
591          </div>  <!-- /apiGroup -->
592
593          <!-- EVENTS -->
594          <div id="eventsTemplate" class="apiGroup">
595            <a name="global-events"></a>
596            <h3>Events</h3>
597            <!-- iterates over all events -->
598            <div class="apiItem">
599              <a name="event-onFinished"></a>
600              <h4>onFinished</h4>
601
602              <div class="summary">
603                <!-- Note: intentionally longer 80 columns -->
604                <span class="subdued">experimental.webInspector.resources.</span><span>onFinished</span><span class="subdued">.addListener</span>(function(<span>Resource resource</span>) <span class="subdued">{...}</span>);
605              </div>
606
607              <div class="description">
608                <p class="todo" style="display: none; ">Undocumented.</p>
609                <p>Fired when a resource request is finished and all resource data are available.</p>
610
611                <!-- PARAMETERS -->
612                <div>
613                  <h4>Parameters</h4>
614                  <dl>
615                    <div>
616                      <div>
617          <dt>
618            <var>resource</var>
619              <em>
620
621                <!-- TYPE -->
622                <div style="display:inline">
623                  (
624                    <span class="optional" style="display: none; ">optional</span>
625                    <span class="enum" style="display: none; ">enumerated</span>
626                    <span id="typeTemplate">
627                      <span>
628                        <a href="experimental.webInspector.resources.html#type-Resource">Resource</a>
629                      </span>
630                      <span style="display: none; ">
631                        <span>
632                          array of <span><span></span></span>
633                        </span>
634                        <span>paramType</span>
635                        <span></span>
636                      </span>
637                    </span>
638                  )
639                </div>
640
641              </em>
642          </dt>
643          <dd class="todo">
644            Undocumented.
645          </dd>
646          <dd style="display: none; ">
647            Description of this parameter from the json schema.
648          </dd>
649          <dd style="display: none; ">
650            This parameter was added in version
651            <b><span></span></b>.
652            You must omit this parameter in earlier versions,
653            and you may omit it in any version.  If you require this
654            parameter, the manifest key
655            <a href="manifest.html#minimum_chrome_version">minimum_chrome_version</a>
656            can ensure that your extension won't be run in an earlier browser version.
657          </dd>
658
659          <!-- OBJECT PROPERTIES -->
660          <dd style="display: none; ">
661            <dl>
662              <div>
663                <div>
664                </div>
665              </div>
666            </dl>
667          </dd>
668
669          <!-- OBJECT METHODS -->
670          <dd style="display: none; ">
671            <div></div>
672          </dd>
673
674          <!-- OBJECT EVENT FIELDS -->
675          <dd style="display: none; ">
676            <div></div>
677          </dd>
678
679          <!-- FUNCTION PARAMETERS -->
680          <dd style="display: none; ">
681            <div></div>
682          </dd>
683
684        </div>
685                    </div>
686                  </dl>
687                </div>
688              </div> <!-- /decription -->
689
690            </div> <!-- /apiItem -->
691
692          </div> <!-- /apiGroup -->
693
694          <!-- TYPES -->
695          <div class="apiGroup">
696            <a name="types"></a>
697            <h3 id="types">Types</h3>
698
699            <!-- iterates over all types -->
700            <div class="apiItem">
701              <a name="type-Resource"></a>
702              <h4>Resource</h4>
703
704              <div>
705          <dt>
706            <var style="display: none; ">paramName</var>
707              <em>
708
709                <!-- TYPE -->
710                <div style="display:inline">
711                  (
712                    <span class="optional" style="display: none; ">optional</span>
713                    <span class="enum" style="display: none; ">enumerated</span>
714                    <span id="typeTemplate">
715                      <span style="display: none; ">
716                        <a> Type</a>
717                      </span>
718                      <span>
719                        <span style="display: none; ">
720                          array of <span><span></span></span>
721                        </span>
722                        <span>object</span>
723                        <span style="display: none; "></span>
724                      </span>
725                    </span>
726                  )
727                </div>
728
729              </em>
730          </dt>
731          <dd class="todo" style="display: none; ">
732            Undocumented.
733          </dd>
734          <dd>Represents a resource (document, script, image etc). See HAR Specification for reference.</dd>
735          <dd style="display: none; ">
736            This parameter was added in version
737            <b><span></span></b>.
738            You must omit this parameter in earlier versions,
739            and you may omit it in any version.  If you require this
740            parameter, the manifest key
741            <a href="manifest.html#minimum_chrome_version">minimum_chrome_version</a>
742            can ensure that your extension won't be run in an earlier browser version.
743          </dd>
744
745          <!-- OBJECT PROPERTIES -->
746          <dd style="display: none; ">
747            <dl>
748              <div>
749                <div>
750                </div>
751              </div>
752            </dl>
753          </dd>
754
755          <!-- OBJECT METHODS -->
756          <dd>
757            <div class="apiGroup">
758            <a name="global-Resource-methods"></a>
759            <h3>Methods of Resource</h3>
760
761            <!-- iterates over all functions -->
762            <div class="apiItem">
763              <a name="method-Resource-getContent"></a> <!-- method-anchor -->
764              <h4>getContent</h4>
765
766              <div class="summary"><span style="display: none; ">void</span>
767                  <!-- Note: intentionally longer 80 columns -->
768                  <span>resource.getContent</span>(<span class="null"><span style="display: none; ">, </span><span>function</span>
769                      <var><span>callback</span></var></span>)</div>
770
771              <div class="description">
772                <p class="todo" style="display: none; ">Undocumented.</p>
773                <p>Returns resource content.</p>
774
775                <!-- PARAMETERS -->
776                <h4>Parameters</h4>
777                <dl>
778                  <div>
779                    <div>
780          <dt>
781            <var>callback</var>
782              <em>
783
784                <!-- TYPE -->
785                <div style="display:inline">
786                  (
787                    <span class="optional" style="display: none; ">optional</span>
788                    <span class="enum" style="display: none; ">enumerated</span>
789                    <span id="typeTemplate">
790                      <span style="display: none; ">
791                        <a> Type</a>
792                      </span>
793                      <span>
794                        <span style="display: none; ">
795                          array of <span><span></span></span>
796                        </span>
797                        <span>function</span>
798                        <span style="display: none; "></span>
799                      </span>
800                    </span>
801                  )
802                </div>
803
804              </em>
805          </dt>
806          <dd class="todo" style="display: none; ">
807            Undocumented.
808          </dd>
809          <dd>A function that is called upon request completion.</dd>
810          <dd style="display: none; ">
811            This parameter was added in version
812            <b><span></span></b>.
813            You must omit this parameter in earlier versions,
814            and you may omit it in any version.  If you require this
815            parameter, the manifest key
816            <a href="manifest.html#minimum_chrome_version">minimum_chrome_version</a>
817            can ensure that your extension won't be run in an earlier browser version.
818          </dd>
819
820          <!-- OBJECT PROPERTIES -->
821          <dd style="display: none; ">
822            <dl>
823              <div>
824                <div>
825                </div>
826              </div>
827            </dl>
828          </dd>
829
830          <!-- OBJECT METHODS -->
831          <dd style="display: none; ">
832            <div></div>
833          </dd>
834
835          <!-- OBJECT EVENT FIELDS -->
836          <dd style="display: none; ">
837            <div></div>
838          </dd>
839
840          <!-- FUNCTION PARAMETERS -->
841          <dd style="display: none; ">
842            <div></div>
843          </dd>
844
845        </div>
846                  </div>
847                </dl>
848
849                <!-- RETURNS -->
850                <h4 style="display: none; ">Returns</h4>
851                <dl>
852                  <div style="display: none; ">
853                    <div>
854                    </div>
855                  </div>
856                </dl>
857
858                <!-- CALLBACK -->
859                <div>
860                  <div>
861                  <h4>Callback function</h4>
862                  <p>
863                    The callback <em>parameter</em> should specify a function
864                    that looks like this:
865                  </p>
866                  <p style="display: none; ">
867                    If you specify the <em>callback</em> parameter, it should
868                    specify a function that looks like this:
869                  </p>
870
871                  <!-- Note: intentionally longer 80 columns -->
872                  <pre>function(<span>string content, string encoding</span>) <span class="subdued">{...}</span>;</pre>
873                  <dl>
874                    <div>
875                      <div>
876          <dt>
877            <var>content</var>
878              <em>
879
880                <!-- TYPE -->
881                <div style="display:inline">
882                  (
883                    <span class="optional" style="display: none; ">optional</span>
884                    <span class="enum" style="display: none; ">enumerated</span>
885                    <span id="typeTemplate">
886                      <span style="display: none; ">
887                        <a> Type</a>
888                      </span>
889                      <span>
890                        <span style="display: none; ">
891                          array of <span><span></span></span>
892                        </span>
893                        <span>string</span>
894                        <span style="display: none; "></span>
895                      </span>
896                    </span>
897                  )
898                </div>
899
900              </em>
901          </dt>
902          <dd class="todo" style="display: none; ">
903            Undocumented.
904          </dd>
905          <dd>Resource content (potentially encoded).</dd>
906          <dd style="display: none; ">
907            This parameter was added in version
908            <b><span></span></b>.
909            You must omit this parameter in earlier versions,
910            and you may omit it in any version.  If you require this
911            parameter, the manifest key
912            <a href="manifest.html#minimum_chrome_version">minimum_chrome_version</a>
913            can ensure that your extension won't be run in an earlier browser version.
914          </dd>
915
916          <!-- OBJECT PROPERTIES -->
917          <dd style="display: none; ">
918            <dl>
919              <div>
920                <div>
921                </div>
922              </div>
923            </dl>
924          </dd>
925
926          <!-- OBJECT METHODS -->
927          <dd style="display: none; ">
928            <div></div>
929          </dd>
930
931          <!-- OBJECT EVENT FIELDS -->
932          <dd style="display: none; ">
933            <div></div>
934          </dd>
935
936          <!-- FUNCTION PARAMETERS -->
937          <dd style="display: none; ">
938            <div></div>
939          </dd>
940
941        </div>
942                    </div><div>
943                      <div>
944          <dt>
945            <var>encoding</var>
946              <em>
947
948                <!-- TYPE -->
949                <div style="display:inline">
950                  (
951                    <span class="optional" style="display: none; ">optional</span>
952                    <span class="enum" style="display: none; ">enumerated</span>
953                    <span id="typeTemplate">
954                      <span style="display: none; ">
955                        <a> Type</a>
956                      </span>
957                      <span>
958                        <span style="display: none; ">
959                          array of <span><span></span></span>
960                        </span>
961                        <span>string</span>
962                        <span style="display: none; "></span>
963                      </span>
964                    </span>
965                  )
966                </div>
967
968              </em>
969          </dt>
970          <dd class="todo" style="display: none; ">
971            Undocumented.
972          </dd>
973          <dd>Empty if content is not encoded, encoding name otherwise. Currently, only base64 supported.</dd>
974          <dd style="display: none; ">
975            This parameter was added in version
976            <b><span></span></b>.
977            You must omit this parameter in earlier versions,
978            and you may omit it in any version.  If you require this
979            parameter, the manifest key
980            <a href="manifest.html#minimum_chrome_version">minimum_chrome_version</a>
981            can ensure that your extension won't be run in an earlier browser version.
982          </dd>
983
984          <!-- OBJECT PROPERTIES -->
985          <dd style="display: none; ">
986            <dl>
987              <div>
988                <div>
989                </div>
990              </div>
991            </dl>
992          </dd>
993
994          <!-- OBJECT METHODS -->
995          <dd style="display: none; ">
996            <div></div>
997          </dd>
998
999          <!-- OBJECT EVENT FIELDS -->
1000          <dd style="display: none; ">
1001            <div></div>
1002          </dd>
1003
1004          <!-- FUNCTION PARAMETERS -->
1005          <dd style="display: none; ">
1006            <div></div>
1007          </dd>
1008
1009        </div>
1010                    </div>
1011                  </dl>
1012                  </div>
1013                </div>
1014
1015                <!-- MIN_VERSION -->
1016                <p style="display: none; ">
1017                  This function was added in version <b><span></span></b>.
1018                  If you require this function, the manifest key
1019                  <a href="manifest.html#minimum_chrome_version">minimum_chrome_version</a>
1020                  can ensure that your extension won't be run in an earlier browser version.
1021                </p>
1022              </div> <!-- /description -->
1023
1024            </div>  <!-- /apiItem -->
1025
1026          </div>
1027          </dd>
1028
1029          <!-- OBJECT EVENT FIELDS -->
1030          <dd style="display: none; ">
1031            <div></div>
1032          </dd>
1033
1034          <!-- FUNCTION PARAMETERS -->
1035          <dd style="display: none; ">
1036            <div></div>
1037          </dd>
1038
1039        </div>
1040
1041            </div> <!-- /apiItem -->
1042
1043          </div> <!-- /apiGroup -->
1044
1045        </div> <!-- /apiPage -->
1046      </div> <!-- /gc-pagecontent -->
1047    </div> <!-- /g-section -->
1048  </div> <!-- /codesiteContent -->
1049    <div id="gc-footer" --="">
1050      <div class="text">
1051  <p>
1052  Except as otherwise <a href="http://code.google.com/policies.html#restrictions">noted</a>,
1053  the content of this page is licensed under the <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons
1054  Attribution 3.0 License</a>, and code samples are licensed under the
1055  <a rel="license" href="http://code.google.com/google_bsd_license.html">BSD License</a>.
1056  </p>
1057  <p>
1058  ©2011 Google
1059  </p>
1060
1061<!-- begin analytics -->
1062<script src="http://www.google-analytics.com/urchin.js" type="text/javascript"></script>
1063<script src="http://www.google-analytics.com/ga.js" type="text/javascript"></script>
1064
1065<script type="text/javascript">
1066  // chrome doc tracking
1067  try {
1068    var engdocs = _gat._getTracker("YT-10763712-2");
1069    engdocs._trackPageview();
1070  } catch(err) {}
1071
1072  // code.google.com site-wide tracking
1073  try {
1074    _uacct="UA-18071-1";
1075    _uanchor=1;
1076    _uff=0;
1077    urchinTracker();
1078  }
1079  catch(e) {/* urchinTracker not available. */}
1080</script>
1081<!-- end analytics -->
1082      </div>
1083    </div> <!-- /gc-footer -->
1084  </div> <!-- /gc-container -->
1085</body></html>
1086