[][src]Struct plugin_tls::LocalKey

pub struct LocalKey<T: 'static> { /* fields omitted */ }

A key into thread-local storage.

Implementations

impl<T: 'static> LocalKey<T>[src]

pub fn with<F, R>(&'static self, f: F) -> R where
    F: FnOnce(&T) -> R, 
[src]

Acquires a reference to the value in this TLS key.

If neither host nor plugin features are enabled, this will panic.

Auto Trait Implementations

impl<T> RefUnwindSafe for LocalKey<T>

impl<T> Send for LocalKey<T>

impl<T> Sync for LocalKey<T>

impl<T> Unpin for LocalKey<T>

impl<T> UnwindSafe for LocalKey<T>

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> GetWithMetadata for T[src]

type ForSelf = WithMetadata_<T, T>

This is always WithMetadata_<Self, Self>

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

impl<T> SelfOps for T where
    T: ?Sized

impl<This> TransmuteElement for This where
    This: ?Sized
[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.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

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

The error type returned when the conversion fails.

impl<T> TypeIdentity for T where
    T: ?Sized

type Type = T

The same type as Self. Read more