pub trait Instance<A>: Sized + WasmNotSendSyncwhere
A: Api,{
// Required methods
unsafe fn init(desc: &InstanceDescriptor<'_>) -> Result<Self, InstanceError>;
unsafe fn create_surface(
&self,
display_handle: RawDisplayHandle,
window_handle: RawWindowHandle
) -> Result<<A as Api>::Surface, InstanceError>;
unsafe fn destroy_surface(&self, surface: <A as Api>::Surface);
unsafe fn enumerate_adapters(&self) -> Vec<ExposedAdapter<A>>;
}
Required Methods§
unsafe fn init(desc: &InstanceDescriptor<'_>) -> Result<Self, InstanceError>
unsafe fn create_surface( &self, display_handle: RawDisplayHandle, window_handle: RawWindowHandle ) -> Result<<A as Api>::Surface, InstanceError>
unsafe fn destroy_surface(&self, surface: <A as Api>::Surface)
unsafe fn enumerate_adapters(&self) -> Vec<ExposedAdapter<A>>
Object Safety§
This trait is not object safe.