Struct sharedlib::DataTracked [] [src]

pub struct DataTracked<T, TLib> {
    // some fields omitted
}

A pointer to shared data which allows a user-provided ref-counting implementation to avoid outliving its library.

Methods

impl<T, TLib> DataTracked<T, TLib> where TLib: AsRef<LibUnsafe> + Clone
[src]

fn new(data: DataUnsafe<T>, lib: TLib) -> Self

Creates a new DataTracked. This should only be called within the library.

Trait Implementations

impl<'a, T, TLib> Symbol<&'a T> for DataTracked<T, TLib>
[src]

unsafe fn get(&self) -> &'a T

Provides access to the data that this symbol references. Read more

Derived Implementations

impl<T: Debug, TLib: Debug> Debug for DataTracked<T, TLib>
[src]

fn fmt(&self, __arg_0: &mut Formatter) -> Result

Formats the value using the given formatter.

impl<T: Clone, TLib: Clone> Clone for DataTracked<T, TLib>
[src]

fn clone(&self) -> DataTracked<T, TLib>

Returns a copy of the value. Read more

fn clone_from(&mut self, source: &Self)
1.0.0

Performs copy-assignment from source. Read more