Struct xpcom::interfaces::nsIUnicharStreamLoaderObserver [] [src]

#[repr(C)]
pub struct nsIUnicharStreamLoaderObserver { /* fields omitted */ }

interface nsIUnicharStreamLoaderObserver : nsISupports

Methods

impl nsIUnicharStreamLoaderObserver
[src]

[src]

Cast this nsIUnicharStreamLoaderObserver to one of its base interfaces.

impl nsIUnicharStreamLoaderObserver
[src]

[src]

/**
   * Called as soon as at least 512 octets of data have arrived.
   * If the stream receives fewer than 512 octets of data in total,
   * called upon stream completion but before calling OnStreamComplete.
   * Will not be called if the stream receives no data at all.
   *
   * @param aLoader the unichar stream loader
   * @param aContext the context parameter of the underlying channel
   * @param aSegment up to 512 octets of raw data from the stream
   *
   * @return the name of the character set to be used to decode this stream
   */

ACString onDetermineCharset (in nsIUnicharStreamLoader aLoader, in nsISupports aContext, in ACString aSegment);

[src]

/**
   * Called when the entire stream has been loaded and decoded.
   *
   * @param aLoader the unichar stream loader
   * @param aContext the context parameter of the underlying channel
   * @param aStatus the status of the underlying channel
   * @param aBuffer the contents of the stream, decoded to UTF-16.
   *
   * This method will always be called asynchronously by the
   * nsUnicharIStreamLoader involved, on the thread that called the
   * loader's init() method.  If onDetermineCharset fails,
   * onStreamComplete will still be called, but aStatus will be an
   * error code.
   */

void onStreamComplete (in nsIUnicharStreamLoader aLoader, in nsISupports aContext, in nsresult aStatus, in AString aBuffer);

Methods from Deref<Target = nsISupports>

[src]

Cast this nsISupports to one of its base interfaces.

[src]

void QueryInterface (in nsIIDRef uuid, [iid_is (uuid), retval] out nsQIResult result);

[src]

[noscript,notxpcom] nsrefcnt AddRef ();

[src]

[noscript,notxpcom] nsrefcnt Release ();

Trait Implementations

impl XpCom for nsIUnicharStreamLoaderObserver
[src]

IID: nsIID = nsID(3264752441, 11848, 17054, [146, 183, 153, 52, 138, 22, 51, 197])

[src]

Perform a QueryInterface call on this object, attempting to dynamically cast it to the requested interface type. Returns Some(RefPtr) if the cast succeeded, and None otherwise. Read more

impl RefCounted for nsIUnicharStreamLoaderObserver
[src]

[src]

Increment the reference count.

[src]

Decrement the reference count, potentially freeing backing memory.

impl Deref for nsIUnicharStreamLoaderObserver
[src]

The resulting type after dereferencing.

[src]

Dereferences the value.