pub trait InterfaceRole: 'static {
type Interface: InterfaceSchema + Send + Sync;
type Config: Owned;
type Init: Owned;
type Stubs;
type Hooks: Clone + 'static;
// Required method
fn setup_worker(
i: &Self::Interface,
ii: &mut RoleSetup<'_>,
config: &Self::Config,
init: &Self::Init,
) -> (Self::Stubs, Self::Hooks);
}Required Associated Types§
type Interface: InterfaceSchema + Send + Sync
type Config: Owned
type Init: Owned
type Stubs
type Hooks: Clone + 'static
Required Methods§
fn setup_worker( i: &Self::Interface, ii: &mut RoleSetup<'_>, config: &Self::Config, init: &Self::Init, ) -> (Self::Stubs, Self::Hooks)
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.