nsIStreamListener

IID:1a637020-1482-11d3-9333-00104ba0fd40
Inherits From:nsIRequestObserver
Status:FROZEN

This interface is implemented by the following components:


Methods

void onDataAvailable ( nsIRequest request , nsISupports context , nsIInputStream inputStream , PRUint32 offset , PRUint32 count )

void onDataAvailable ( nsIRequest request , nsISupports context , nsIInputStream inputStream , PRUint32 offset , PRUint32 count )

Called when the next chunk of data (corresponding to the request) may be read without blocking the calling thread. The onDataAvailable impl must read exactly count bytes of data before returning.

NOTE: The inputStream parameter must implement readSegments.

An exception thrown from onDataAvailable has the side-effect of causing the request to be canceled.

Arguments:
request: request corresponding to the source of the data
context: user defined context
inputStream: input stream containing the data chunk
offset: current stream position
count: number of bytes available in the stream

References

This interface is the type of the following properties:

nsIMailboxUrl.mailboxCopyHandler, nsIMailboxUrl.mailboxParser, nsIMsgQuote.streamListener

This interface is passed as an argument to the following methods:

imgILoader.loadImageWithChannel, nsIAsyncStreamListener.init, nsIChannel.asyncOpen, nsIDocumentLoaderFactory.createInstance, nsIImapMockChannel.GetChannelListener, nsIInputStreamPump.asyncRead, nsIMailboxService.ParseMailbox, nsIMimeEmitter.SetOutputListener, nsIMsgMessageService.CopyMessage, nsIMsgMessageService.CopyMessages, nsIMsgQuote.QuoteMessage, nsIPluginDocument.setStreamListener, nsIStreamConverter.asyncConvertData, nsIStreamConverterService.asyncConvertData, nsIStreamListenerProxy.init, nsIStreamListenerTee.init, nsIURIContentListener.doContent

This interface is returned from the following methods:

nsIExternalHelperAppService.doContent, nsIImageLoadingContent.loadImageWithChannel, nsIMimeEmitter.GetOutputListener, nsIMsgMailNewsUrl.getSaveAsListener, nsIRDFXMLParser.parseAsync, nsIStreamConverterService.asyncConvertData

Reference documentation is generated from Mozilla's source.