Trait Ptr

Source
pub trait Ptr: Sealed {
    type A: ?Sized;
    type Weak: Weak<A = Self::A, Strong = Self>;

    // Required methods
    fn inner(&self) -> &Self::A;
    fn value(&self) -> *const Self::A;
    fn weak(&self) -> Self::Weak;
}

Required Associated Typesยง

Source

type A: ?Sized

Source

type Weak: Weak<A = Self::A, Strong = Self>

Required Methodsยง

Source

fn inner(&self) -> &Self::A

Source

fn value(&self) -> *const Self::A

Source

fn weak(&self) -> Self::Weak

Implementations on Foreign Typesยง

Sourceยง

impl<A: ?Sized> Ptr for Rc<A>

Sourceยง

type A = A

Sourceยง

type Weak = Weak<A>

Sourceยง

fn inner(&self) -> &A

Sourceยง

fn value(&self) -> *const A

Sourceยง

fn weak(&self) -> Self::Weak

Sourceยง

impl<A: ?Sized> Ptr for Arc<A>

Sourceยง

type A = A

Sourceยง

type Weak = Weak<A>

Sourceยง

fn inner(&self) -> &A

Sourceยง

fn value(&self) -> *const A

Sourceยง

fn weak(&self) -> Self::Weak

Implementorsยง