Struct xpcom::interfaces::nsIStructuredCloneContainer
[−]
[src]
#[repr(C)]pub struct nsIStructuredCloneContainer { /* fields omitted */ }
interface nsIStructuredCloneContainer : nsISupports
/**
* This interface acts as a container for an object serialized using the
* structured clone algorithm.
*
* You can copy an object into an nsIStructuredCloneContainer using
* initFromJSVal or initFromBase64. It's an error to initialize an
* nsIStructuredCloneContainer more than once.
*
* Once you've initialized the container, you can get a copy of the object it
* stores by calling deserializeToVariant. You can also get a base-64-encoded
* string containing a copy of the container's serialized data, using
* getDataAsBase64.
*/
Methods
impl nsIStructuredCloneContainer
[src]
pub fn coerce<T: nsIStructuredCloneContainerCoerce>(&self) -> &T
[src]
Cast this nsIStructuredCloneContainer
to one of its base interfaces.
impl nsIStructuredCloneContainer
[src]
pub unsafe fn InitFromBase64(
&self,
aData: &nsAString,
aFormatVersion: uint32_t
) -> nsresult
[src]
&self,
aData: &nsAString,
aFormatVersion: uint32_t
) -> nsresult
/**
* Initialize this structured clone container from a base-64-encoded byte
* stream, stored in aData. aFormatVersion should be the version of the
* structured clone algorithm which was used to generate aData.
*/
void initFromBase64 (in AString aData, in unsigned long aFormatVersion);
pub unsafe fn GetDataAsBase64(&self, _retval: &mut nsAString) -> nsresult
[src]
/**
* Get this structured clone container's data as a base-64-encoded string.
*/
AString getDataAsBase64 ();
pub unsafe fn GetSerializedNBytes(
&self,
aSerializedNBytes: *mut uint64_t
) -> nsresult
[src]
&self,
aSerializedNBytes: *mut uint64_t
) -> nsresult
/**
* Get the size in bytes of this container's serialized data.
*/
readonly attribute unsigned long long serializedNBytes;
pub unsafe fn GetFormatVersion(&self, aFormatVersion: *mut uint32_t) -> nsresult
[src]
/**
* Get the version of the structured clone algorithm which was used to
* generate this container's serialized buffer.
*/
readonly attribute unsigned long formatVersion;
Methods from Deref<Target = nsISupports>
pub fn coerce<T: nsISupportsCoerce>(&self) -> &T
[src]
Cast this nsISupports
to one of its base interfaces.
pub unsafe fn QueryInterface(
&self,
uuid: &nsIID,
result: *mut *mut c_void
) -> nsresult
[src]
&self,
uuid: &nsIID,
result: *mut *mut c_void
) -> nsresult
void QueryInterface (in nsIIDRef uuid, [iid_is (uuid), retval] out nsQIResult result);
pub unsafe fn AddRef(&self) -> nsrefcnt
[src]
[noscript,notxpcom] nsrefcnt AddRef ();
pub unsafe fn Release(&self) -> nsrefcnt
[src]
[noscript,notxpcom] nsrefcnt Release ();
Trait Implementations
impl XpCom for nsIStructuredCloneContainer
[src]
const IID: nsIID
IID: nsIID = nsID(3328486119, 3431, 16725, [162, 221, 163, 134, 23, 120, 98, 111])
fn query_interface<T: XpCom>(&self) -> Option<RefPtr<T>>
[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 nsIStructuredCloneContainer
[src]
unsafe fn addref(&self)
[src]
Increment the reference count.
unsafe fn release(&self)
[src]
Decrement the reference count, potentially freeing backing memory.
impl Deref for nsIStructuredCloneContainer
[src]
type Target = nsISupports
The resulting type after dereferencing.
fn deref(&self) -> &nsISupports
[src]
Dereferences the value.