Trait Pointer

Source
pub trait Pointer {
    type Target: ?Sized;

    // Required method
    fn get(&self) -> *const Self::Target;
}
Expand description

Type that stores its value in an allocation and can retrieve a pointer to the value.

Required Associated Types§

Required Methods§

Source

fn get(&self) -> *const Self::Target

Get a read-only pointer to the value.

Implementations on Foreign Types§

Source§

impl<T> Pointer for &[T]

Source§

type Target = T

Source§

fn get(&self) -> *const Self::Target

Source§

impl<T> Pointer for Vec<T>

Source§

type Target = T

Source§

fn get(&self) -> *const Self::Target

Source§

impl<T: ?Sized> Pointer for Box<T>

Source§

type Target = T

Source§

fn get(&self) -> *const Self::Target

Source§

impl<T: ?Sized> Pointer for Rc<T>

Source§

type Target = T

Source§

fn get(&self) -> *const Self::Target

Source§

impl<T: ?Sized> Pointer for Arc<T>

Source§

type Target = T

Source§

fn get(&self) -> *const Self::Target

Source§

impl<const LEN: usize, T> Pointer for &[T; LEN]

Source§

type Target = T

Source§

fn get(&self) -> *const Self::Target

Implementors§