Bug 1845134 - Part 4: Update existing ui-icons to use the latest source from acorn...
[gecko.git] / netwerk / base / nsIHttpPushListener.idl
blobf44605c00068d707d3637ad371c33b7557357a4e
1 /* This Source Code Form is subject to the terms of the Mozilla Public
2 * License, v. 2.0. If a copy of the MPL was not distributed with this
3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
5 #include "nsISupports.idl"
6 interface nsIHttpChannel;
8 /**
9 * nsIHttpPushListener
11 * Used for triggering when a HTTP/2 push is received.
14 [scriptable, uuid(0d6ce59c-ad5d-4520-b4d3-09664868f279)]
15 interface nsIHttpPushListener : nsISupports
17 /**
18 * When provided as a notificationCallback to an httpChannel, this.onPush()
19 * will be invoked when there is a >= Http2 push to that
20 * channel. The push may be in progress.
22 * The consumer must start the new channel in the usual way by calling
23 * pushChannel.AsyncOpen with a nsIStreamListener object that
24 * will receive the normal sequence of OnStartRequest(),
25 * 0 to N OnDataAvailable(), and onStopRequest().
27 * The new channel can be canceled after the AsyncOpen if it is not wanted.
29 * @param associatedChannel
30 * the monitor channel that was recieved on
31 * @param pushChannel
32 * a channel to the resource which is being pushed
34 void onPush(in nsIHttpChannel associatedChannel,
35 in nsIHttpChannel pushChannel);