Skip to main content

ServiceKey

Trait ServiceKey 

Source
pub trait ServiceKey:
    Send
    + Sync
    + 'static {
    type Value: ?Sized + Send + Sync + 'static;

    const NAME: &'static str;
}
Expand description

Typed service key. The associated value may be unsized, including a trait object such as dyn Database.

Required Associated Constants§

Source

const NAME: &'static str

Required Associated Types§

Source

type Value: ?Sized + Send + Sync + 'static

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§