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

Side by Side Diff: chrome/common/extensions/api/streams_private.idl

Issue 281513003: Implement chrome.streamsPrivate.abort() extensions function (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 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
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 callback AbortCallback = void ();
33
34 interface Functions {
35 // Abort the URL request on the given stream.
36 // |streamUrl| : The URL of the stream to abort.
37 // |callback| : Called when the stream URL is guaranteed to be invalid. The
38 // underlying URL request may not yet have been aborted when this is run.
39 static void abort(DOMString streamUrl,
40 AbortCallback callback);
not at google - send to devlin 2014/05/23 17:03:48 consider making this optional.
41 };
42
32 interface Events { 43 interface Events {
33 // Fired when a resource is fetched which matches a mime type handled by 44 // 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 45 // 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 46 // expected to handle the request. The event is restricted to a small number
36 // of white-listed extensions. 47 // of white-listed extensions.
37 static void onExecuteMimeTypeHandler(StreamInfo streamInfo); 48 static void onExecuteMimeTypeHandler(StreamInfo streamInfo);
38 }; 49 };
39 }; 50 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698