[−][src]Struct c_bridge::FfiObject
A FFI object
Methods
impl FfiObject
[src]
pub const OPAQUE: u64
[src]
Indicates an opaque object
pub const DATA_ARRAY: u64
[src]
A byte array
pub const OBJECT_ARRAY: u64
[src]
An object array
pub const RUST_BOX: u64
[src]
An owned, boxed Rust object
pub const CUSTOM_MASK: u64
[src]
The mask for custom types
Warning: you have to ensure that you don't define the same value twice for different
types. If you don't need to check against the type later, use OPAQUE
.
pub fn release(&mut self)
[src]
Releases the payload if the struct is owned and sets it to unowned and empty in any case
Trait Implementations
impl<T: 'static> From<GenericArray<T>> for FfiObject
[src]
fn from(array: GenericArray<T>) -> Self
[src]
impl From<RustBox> for FfiObject
[src]
impl Drop for FfiObject
[src]
impl<T: 'static> TryFrom<FfiObject> for GenericArray<T>
[src]
type Error = FfiObject
The type returned in the event of a conversion error.
fn try_from(object: FfiObject) -> Result<Self, Self::Error>
[src]
Converts object
into the array if it has the correct type and is not empty
impl TryFrom<FfiObject> for RustBox
[src]
Auto Trait Implementations
impl !Send for FfiObject
impl Unpin for FfiObject
impl !Sync for FfiObject
impl RefUnwindSafe for FfiObject
impl UnwindSafe for FfiObject
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,