Struct gdnative_core::export::user_data::MutexData
source · pub struct MutexData<T, OPT = DefaultLockPolicy> { /* private fields */ }Expand description
User-data wrapper encapsulating a Arc<Mutex<T>>.
The underlying Mutex may change in the future. The current implementation is
parking_lot.
Trait Implementations§
source§impl<T, OPT> Map for MutexData<T, OPT>where
T: NativeClass + Send,
OPT: LockOptions,
impl<T, OPT> Map for MutexData<T, OPT>where
T: NativeClass + Send,
OPT: LockOptions,
source§impl<T, OPT> MapMut for MutexData<T, OPT>where
T: NativeClass + Send,
OPT: LockOptions,
impl<T, OPT> MapMut for MutexData<T, OPT>where
T: NativeClass + Send,
OPT: LockOptions,
source§impl<T, OPT> UserData for MutexData<T, OPT>where
T: NativeClass + Send,
OPT: LockOptions,
impl<T, OPT> UserData for MutexData<T, OPT>where
T: NativeClass + Send,
OPT: LockOptions,
type Target = T
source§fn new(val: Self::Target) -> Self
fn new(val: Self::Target) -> Self
Creates a new owned wrapper from a
NativeClass instance. Read moresource§fn into_user_data(self) -> *const c_void
fn into_user_data(self) -> *const c_void
Takes a native instance and returns an opaque pointer that can be used to recover it. Read more