[][src]Trait two_sided_vec::TwoSidedIndex

pub trait TwoSidedIndex<T>: Sized + Debug {
    type Output: ?Sized;
    unsafe fn get_unchecked(self, target: &TwoSidedVec<T>) -> &Self::Output;
unsafe fn get_unchecked_mut(
        self,
        target: &mut TwoSidedVec<T>
    ) -> &mut Self::Output;
fn check(&self, target: &TwoSidedVec<T>) -> bool; fn get(self, target: &TwoSidedVec<T>) -> Option<&Self::Output> { ... }
fn get_mut(self, target: &mut TwoSidedVec<T>) -> Option<&mut Self::Output> { ... }
fn index(self, target: &TwoSidedVec<T>) -> &Self::Output { ... }
fn index_mut(self, target: &mut TwoSidedVec<T>) -> &mut Self::Output { ... }
fn invalid(self) -> ! { ... } }

Associated Types

type Output: ?Sized

Loading content...

Required methods

unsafe fn get_unchecked(self, target: &TwoSidedVec<T>) -> &Self::Output

Use this as an index against the specified vec

Safety

Undefined behavior if the index is out of bounds

unsafe fn get_unchecked_mut(
    self,
    target: &mut TwoSidedVec<T>
) -> &mut Self::Output

Use this as an index against the specified vec

Safety

Undefined behavior if the index is out of bounds

fn check(&self, target: &TwoSidedVec<T>) -> bool

Loading content...

Provided methods

fn get(self, target: &TwoSidedVec<T>) -> Option<&Self::Output>

fn get_mut(self, target: &mut TwoSidedVec<T>) -> Option<&mut Self::Output>

fn index(self, target: &TwoSidedVec<T>) -> &Self::Output

fn index_mut(self, target: &mut TwoSidedVec<T>) -> &mut Self::Output

fn invalid(self) -> !

Loading content...

Implementations on Foreign Types

impl<T> TwoSidedIndex<T> for isize[src]

type Output = T

impl<T> TwoSidedIndex<T> for Range<isize>[src]

type Output = [T]

impl<T> TwoSidedIndex<T> for RangeFull[src]

type Output = [T]

impl<T> TwoSidedIndex<T> for RangeFrom<isize>[src]

type Output = [T]

impl<T> TwoSidedIndex<T> for RangeTo<isize>[src]

type Output = [T]

Loading content...

Implementors

Loading content...