Interface imgILoaderType

imgILoader interface

Author

Stuart Parmenter pavlov@netscape.com

Version

0.3

See

imagelib2

Hierarchy

Methods

  • Increases the reference count for this interface. The associated instance will not be deleted unless the reference count is returned to zero.

    Returns

    The resulting reference count.

    Returns number

  • Parameters

    • aIID: object
    • Optional aInstancePtr: object

    Returns any

  • A run time mechanism for interface discovery.

    Returns

    NS_OK if the interface is supported by the associated instance, NS_NOINTERFACE if it is not.

    aInstancePtr must not be null.

    Parameters

    • aIID: object

      [in] A requested interface IID

    • aInstancePtr: object

      [out] A pointer to an interface pointer to receive the result.

    Returns void

  • Decreases the reference count for this interface. Generally, if the reference count returns to zero, the associated instance is deleted.

    Returns

    The resulting reference count.

    Returns number

  • Start the load and decode of an image.

    AChannel

    will be canceled for you in this case.

    ImageLib does NOT keep a strong ref to the observer; this prevents reference cycles. This means that callers of loadImageWithChannel should make sure to Cancel() the resulting request before the observer goes away.

    Parameters

    • aChannel: nsIChannel

      the channel to load the image from. This must already be opened before this method is called, and there must have been no OnDataAvailable calls for it yet.

    • aObserver: imgINotificationObserver

      the observer (may be null)

    • aLoadingDocument: Document

      loading document

    • aListener: nsIStreamListener

      [out] A listener that you must send the channel's notifications and data to. Can be null, in which case imagelib has found a cached image and is not interested in the data.

    Returns imgIRequest

  • Start the load and decode of an image.

    Parameters

    • aURI: nsIURI

      the URI to load

    • aInitialDocumentURL: nsIURI
    • aReferrerInfo: nsIReferrerInfo

      the referrer info to compute sending referrer.

    • aLoadingPrincipal: nsIPrincipal

      the principal of the loading document

    • aLoadGroup: nsILoadGroup

      Loadgroup to put the image load into

    • aObserver: imgINotificationObserver

      the observer (may be null)

    • aLoadingDocument: Document

      loading document

    • aLoadFlags: nsLoadFlags

      Load flags for the request

    • cacheKey: nsISupports
    • aContentPolicyType: nsContentPolicyType

      [optional] the nsContentPolicyType to use for this load. Defaults to nsIContentPolicy::TYPE_IMAGE ImageLib does NOT keep a strong ref to the observer; this prevents reference cycles. This means that callers of loadImage should make sure to Cancel() the resulting request before the observer goes away.

    Returns imgIRequest

Generated using TypeDoc