[][src]Struct typed_shmem::ShMem

pub struct ShMem<T> where
    T: AsBytes + FromBytes + Default
{ /* fields omitted */ }

Contains the platform-specific implementation details for shared memory. The memory itself it is accessed through the Deref and DerefMut traits.

It must be created using ShMemCfg or Shared memory configurator.

Drop

When ShMem is dropped, it removes the handle to the shared memory file. If the dropped instance of ShMem is owner, it will try to remove the shared memory file too (on *nix).

To keep in mind

The memory does not implement any form of synchronization. It also draw on UBs to glue Deref and DerefMut traits to the internal implementation.

Trait Implementations

impl<T> Deref for ShMem<T> where
    T: AsBytes + FromBytes + Default
[src]

type Target = T

The resulting type after dereferencing.

impl<T> DerefMut for ShMem<T> where
    T: AsBytes + FromBytes + Default
[src]

Auto Trait Implementations

impl<T> RefUnwindSafe for ShMem<T> where
    T: RefUnwindSafe
[src]

impl<T> !Send for ShMem<T>[src]

impl<T> !Sync for ShMem<T>[src]

impl<T> Unpin for ShMem<T>[src]

impl<T> UnwindSafe for ShMem<T> where
    T: RefUnwindSafe
[src]

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.