Trait HasHandleType

Source
pub trait HasHandleType: Sized {
    // Required method
    fn handle_type<'ty>() -> &'ty HandleType<Self>;

    // Provided method
    fn into_handle<'ty>(self) -> Result<HandleRef<'ty, Self>, HandleError> { ... }
}
Expand description

Implement this trait to allow automatic conversion to HandleRef from native arguments.

Required Methods§

Source

fn handle_type<'ty>() -> &'ty HandleType<Self>

Provided Methods§

Source

fn into_handle<'ty>(self) -> Result<HandleRef<'ty, Self>, HandleError>

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§