Struct xpcom::interfaces::nsIVariant
[−]
[src]
#[repr(C)]pub struct nsIVariant { /* fields omitted */ }
interface nsIVariant : nsISupports
/**
* XPConnect has magic to transparently convert between nsIVariant and JS types.
* We mark the interface [scriptable] so that JS can use methods
* that refer to this interface. But we mark all the methods and attributes
* [noscript] since any nsIVariant object will be automatically converted to a
* JS type anyway.
*/
Methods
impl nsIVariant
[src]
pub fn coerce<T: nsIVariantCoerce>(&self) -> &T
[src]
Cast this nsIVariant
to one of its base interfaces.
impl nsIVariant
[src]
pub unsafe fn GetDataType(&self, aDataType: *mut uint16_t) -> nsresult
[src]
[noscript] readonly attribute uint16_t dataType;
pub unsafe fn GetAsInt8(&self, _retval: *mut uint8_t) -> nsresult
[src]
[noscript] uint8_t getAsInt8 ();
pub unsafe fn GetAsInt16(&self, _retval: *mut int16_t) -> nsresult
[src]
[noscript] int16_t getAsInt16 ();
pub unsafe fn GetAsInt32(&self, _retval: *mut int32_t) -> nsresult
[src]
[noscript] int32_t getAsInt32 ();
pub unsafe fn GetAsInt64(&self, _retval: *mut int64_t) -> nsresult
[src]
[noscript] int64_t getAsInt64 ();
pub unsafe fn GetAsUint8(&self, _retval: *mut uint8_t) -> nsresult
[src]
[noscript] uint8_t getAsUint8 ();
pub unsafe fn GetAsUint16(&self, _retval: *mut uint16_t) -> nsresult
[src]
[noscript] uint16_t getAsUint16 ();
pub unsafe fn GetAsUint32(&self, _retval: *mut uint32_t) -> nsresult
[src]
[noscript] uint32_t getAsUint32 ();
pub unsafe fn GetAsUint64(&self, _retval: *mut uint64_t) -> nsresult
[src]
[noscript] uint64_t getAsUint64 ();
pub unsafe fn GetAsFloat(&self, _retval: *mut c_float) -> nsresult
[src]
[noscript] float getAsFloat ();
pub unsafe fn GetAsDouble(&self, _retval: *mut c_double) -> nsresult
[src]
[noscript] double getAsDouble ();
pub unsafe fn GetAsBool(&self, _retval: *mut bool) -> nsresult
[src]
[noscript] boolean getAsBool ();
pub unsafe fn GetAsChar(&self, _retval: *mut c_char) -> nsresult
[src]
[noscript] char getAsChar ();
pub unsafe fn GetAsWChar(&self, _retval: *mut int16_t) -> nsresult
[src]
[noscript] wchar getAsWChar ();
pub unsafe fn GetAsID(&self, retval: *mut nsID) -> nsresult
[src]
[notxpcom] nsresult getAsID (out nsID retval);
pub unsafe fn GetAsAString(&self, _retval: &mut nsAString) -> nsresult
[src]
[noscript] AString getAsAString ();
pub unsafe fn GetAsDOMString(&self, _retval: &mut nsAString) -> nsresult
[src]
[noscript] DOMString getAsDOMString ();
pub unsafe fn GetAsACString(&self, _retval: &mut nsACString) -> nsresult
[src]
[noscript] ACString getAsACString ();
pub unsafe fn GetAsAUTF8String(&self, _retval: &mut nsACString) -> nsresult
[src]
[noscript] AUTF8String getAsAUTF8String ();
pub unsafe fn GetAsString(&self, _retval: *mut *const c_char) -> nsresult
[src]
[noscript] string getAsString ();
pub unsafe fn GetAsWString(&self, _retval: *mut *const int16_t) -> nsresult
[src]
[noscript] wstring getAsWString ();
pub unsafe fn GetAsISupports(
&self,
_retval: *mut *const nsISupports
) -> nsresult
[src]
&self,
_retval: *mut *const nsISupports
) -> nsresult
[noscript] nsISupports getAsISupports ();
pub unsafe fn GetAsInterface(
&self,
iid: *mut *mut nsIID,
iface: *mut *mut c_void
) -> nsresult
[src]
&self,
iid: *mut *mut nsIID,
iface: *mut *mut c_void
) -> nsresult
[noscript] void getAsInterface (out nsIIDPtr iid, [iid_is (iid), retval] out nsQIResult iface);
pub unsafe fn GetAsArray(
&self,
type_: *mut uint16_t,
iid: *mut nsIID,
count: *mut uint32_t,
ptr: *mut *mut c_void
) -> nsresult
[src]
&self,
type_: *mut uint16_t,
iid: *mut nsIID,
count: *mut uint32_t,
ptr: *mut *mut c_void
) -> nsresult
[notxpcom] nsresult getAsArray (out uint16_t type, out nsIID iid, out uint32_t count, out voidPtr ptr);
pub unsafe fn GetAsStringWithSize(
&self,
size: *mut uint32_t,
str: *mut *const c_char
) -> nsresult
[src]
&self,
size: *mut uint32_t,
str: *mut *const c_char
) -> nsresult
[noscript] void getAsStringWithSize (out uint32_t size, [size_is (size), retval] out string str);
pub unsafe fn GetAsWStringWithSize(
&self,
size: *mut uint32_t,
str: *mut *const int16_t
) -> nsresult
[src]
&self,
size: *mut uint32_t,
str: *mut *const int16_t
) -> nsresult
[noscript] void getAsWStringWithSize (out uint32_t size, [size_is (size), retval] out wstring str);
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 nsIVariant
[src]
const IID: nsIID
IID: nsIID = nsID(2179252958, 44204, 19158, [144, 26, 181, 251, 27, 133, 26, 13])
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 nsIVariant
[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 nsIVariant
[src]
type Target = nsISupports
The resulting type after dereferencing.
fn deref(&self) -> &nsISupports
[src]
Dereferences the value.