| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 // Streams Private API. | 5 // Streams Private API. |
| 6 namespace streamsPrivate { | 6 namespace streamsPrivate { |
| 7 dictionary StreamInfo { | 7 dictionary StreamInfo { |
| 8 // The MIME type of the intercepted URL request. | 8 // The MIME type of the intercepted URL request. |
| 9 DOMString mimeType; | 9 DOMString mimeType; |
| 10 | 10 |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 // information on the size it will be -1. | 22 // information on the size it will be -1. |
| 23 long expectedContentSize; | 23 long expectedContentSize; |
| 24 | 24 |
| 25 // The HTTP response headers of the intercepted request stored as a | 25 // The HTTP response headers of the intercepted request stored as a |
| 26 // dictionary mapping header name to header value. If a header name appears | 26 // dictionary mapping header name to header value. If a header name appears |
| 27 // multiple times, the header values are merged in the dictionary and | 27 // multiple times, the header values are merged in the dictionary and |
| 28 // separated by a ", ". | 28 // separated by a ", ". |
| 29 object responseHeaders; | 29 object responseHeaders; |
| 30 }; | 30 }; |
| 31 | 31 |
| 32 interface Functions { |
| 33 // Abort the URL request on the given stream. |
| 34 // |streamUrl| : The URL of the stream to abort. |
| 35 static void abort(DOMString streamUrl); |
| 36 }; |
| 37 |
| 32 interface Events { | 38 interface Events { |
| 33 // Fired when a resource is fetched which matches a mime type handled by | 39 // Fired when a resource is fetched which matches a mime type handled by |
| 34 // this extension. The resource request is cancelled, and the extension is | 40 // this extension. The resource request is cancelled, and the extension is |
| 35 // expected to handle the request. The event is restricted to a small number | 41 // expected to handle the request. The event is restricted to a small number |
| 36 // of white-listed extensions. | 42 // of white-listed extensions. |
| 37 static void onExecuteMimeTypeHandler(StreamInfo streamInfo); | 43 static void onExecuteMimeTypeHandler(StreamInfo streamInfo); |
| 38 }; | 44 }; |
| 39 }; | 45 }; |
| OLD | NEW |