This interface is used by various streams (such as
nsIChannel ) to indicate the start and end of a request.
Inherits from:
nsISupports
Last changed in Gecko 1.0 Method overview
void onStartRequest(in nsIRequest aRequest, in nsISupports aContext); |
void onStopRequest(in nsIRequest aRequest, in nsISupports aContext, in nsresult aStatusCode); |
Methods
onStartRequest()
Called to signify the beginning of an asynchronous request.
Note: An exception thrown from
onStartRequest has the side-effect of causing the request to be canceled.void onStartRequest( in nsIRequest aRequest, in nsISupports aContext );
Parameters
-
aRequest - Request being observed.
-
aContext - User defined context.
onStopRequest()
Called to signify the end of an asynchronous request. This call is always preceded by a call to onStartRequest().
Note: An exception thrown from
onStopRequest is generally ignored.void onStopRequest( in nsIRequest aRequest, in nsISupports aContext, in nsresult aStatusCode );
Parameters
-
aRequest - Request being observed.
-
aContext - User defined context.
-
aStatusCode - Reason for stopping (NS_OK if completed successfully)