[][src]Struct kernel::DynamicGrant

pub struct DynamicGrant<T: ?Sized> { /* fields omitted */ }

Grant which was dynamically allocated in a particular app's memory.

Implementations

impl<T: ?Sized> DynamicGrant<T>[src]

pub fn appid(&self) -> AppId[src]

pub fn enter<F, R>(&mut self, fun: F) -> Result<R, Error> where
    F: FnOnce(Borrowed<'_, T>) -> R, 
[src]

Gives access to inner data within the given closure.

If the app has since been restarted or crashed, or the memory is otherwise no longer present, then this function will not call the given closure, and will instead directly return Err(Error::NoSuchApp).

Because this function requires &mut self, it should be impossible to access the inner data of a given DynamicGrant reentrantly. Thus the reentrance detection we use for non-dynamic grants is not needed here.

Auto Trait Implementations

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

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

impl<T: ?Sized> Unpin for DynamicGrant<T>[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.