Skip to main content

ScopedManager

Trait ScopedManager 

Source
pub trait ScopedManager<P: Payload>: MemoryManager<P> {
    type Handle<'a>: MemoryManager<P> + Send + 'a
       where Self: 'a;

    // Required method
    fn scoped_handle<'a>(&'a self) -> Self::Handle<'a>
       where Self: 'a;
}
Expand description

Scoped handle factory for memory managers used in concurrent execution.

Analogous to ScopedEdge for memory managers. The GAT Handle<'a> allows implementations to return either an owned clone (Arc-based) or a borrowed view (future lock-free managers).

Required Associated Types§

Source

type Handle<'a>: MemoryManager<P> + Send + 'a where Self: 'a

Per-worker handle type.

Required Methods§

Source

fn scoped_handle<'a>(&'a self) -> Self::Handle<'a>
where Self: 'a,

Create a scoped handle for a worker thread.

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§