#[repr(transparent)]pub struct MySlice<T>(pub [T]);
Tuple Fields§
§0: [T]
Trait Implementations§
source§impl<T> Children<u16, T> for MySlice<T>
impl<T> Children<u16, T> for MySlice<T>
fn child_count(&self) -> u16
fn get(&self, i: u16) -> Option<&T>
fn rev(&self, idx: u16) -> Option<&T>
fn after(&self, i: u16) -> &Self
fn before(&self, i: u16) -> &Self
fn between(&self, start: u16, end: u16) -> &Self
fn inclusive(&self, start: u16, end: u16) -> &Self
source§impl<T> Children<u8, T> for MySlice<T>
impl<T> Children<u8, T> for MySlice<T>
fn child_count(&self) -> u8
fn get(&self, i: u8) -> Option<&T>
fn rev(&self, idx: u8) -> Option<&T>
fn after(&self, i: u8) -> &Self
fn before(&self, i: u8) -> &Self
fn between(&self, start: u8, end: u8) -> &Self
fn inclusive(&self, start: u8, end: u8) -> &Self
source§impl<T> IterableChildren<T> for MySlice<T>
impl<T> IterableChildren<T> for MySlice<T>
type ChildrenIter<'a> = Iter<'a, T> where T: 'a
fn iter_children(&self) -> Self::ChildrenIter<'_>
fn is_empty(&self) -> bool
Auto Trait Implementations§
impl<T> RefUnwindSafe for MySlice<T>where T: RefUnwindSafe,
impl<T> Send for MySlice<T>where T: Send,
impl<T> !Sized for MySlice<T>
impl<T> Sync for MySlice<T>where T: Sync,
impl<T> Unpin for MySlice<T>where T: Unpin,
impl<T> UnwindSafe for MySlice<T>where T: UnwindSafe,
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> Pipe for Twhere
T: ?Sized,
impl<T> Pipe for Twhere T: ?Sized,
§fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere Self: Sized,
Pipes by value. This is generally the method you want to use. Read more
§fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere R: 'a,
Borrows
self
and passes that borrow into the pipe function. Read more§fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere R: 'a,
Mutably borrows
self
and passes that borrow into the pipe function. Read more§fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> Rwhere
Self: Borrow<B>,
B: 'a + ?Sized,
R: 'a,
fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> Rwhere Self: Borrow<B>, B: 'a + ?Sized, R: 'a,
§fn pipe_borrow_mut<'a, B, R>(
&'a mut self,
func: impl FnOnce(&'a mut B) -> R
) -> Rwhere
Self: BorrowMut<B>,
B: 'a + ?Sized,
R: 'a,
fn pipe_borrow_mut<'a, B, R>( &'a mut self, func: impl FnOnce(&'a mut B) -> R ) -> Rwhere Self: BorrowMut<B>, B: 'a + ?Sized, R: 'a,
§fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> Rwhere
Self: AsRef<U>,
U: 'a + ?Sized,
R: 'a,
fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> Rwhere Self: AsRef<U>, U: 'a + ?Sized, R: 'a,
Borrows
self
, then passes self.as_ref()
into the pipe function.§fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> Rwhere
Self: AsMut<U>,
U: 'a + ?Sized,
R: 'a,
fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> Rwhere Self: AsMut<U>, U: 'a + ?Sized, R: 'a,
Mutably borrows
self
, then passes self.as_mut()
into the pipe
function.