pub struct Shape { /* private fields */ }Implementations§
Source§impl Shape
impl Shape
pub fn new(dims: &[usize]) -> Self
pub fn dim2(a: usize, b: usize) -> Self
pub fn dim4(a: usize, b: usize, c: usize, d: usize) -> Self
pub fn ndim(&self) -> usize
pub fn dim(&self, i: usize) -> Option<usize>
pub fn num_elements(&self) -> usize
pub fn is_valid(&self) -> bool
Trait Implementations§
impl Eq for Shape
impl StructuralPartialEq for Shape
Auto Trait Implementations§
impl Freeze for Shape
impl RefUnwindSafe for Shape
impl Send for Shape
impl Sync for Shape
impl Unpin for Shape
impl UnsafeUnpin for Shape
impl UnwindSafe for Shape
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