pub struct NdArrayVTableBuilder { /* private fields */ }
Expand description
Builds a NdArrayVTable
Implementations§
Source§impl NdArrayVTableBuilder
impl NdArrayVTableBuilder
Sourcepub const fn new() -> Self
pub const fn new() -> Self
Creates a new NdArrayVTableBuilder
with all fields set to None
.
Sourcepub const fn n_dim(self, f: NdArrayNDimFn) -> Self
pub const fn n_dim(self, f: NdArrayNDimFn) -> Self
Sets the n_dim
field
Sourcepub const fn dim(self, f: NdArrayDimFn) -> Self
pub const fn dim(self, f: NdArrayDimFn) -> Self
Sets the dim
field
Sourcepub const fn get(self, f: NdArrayGetFn) -> Self
pub const fn get(self, f: NdArrayGetFn) -> Self
Sets the get
field
Sourcepub const fn get_mut(self, f: NdArrayGetMutFn) -> Self
pub const fn get_mut(self, f: NdArrayGetMutFn) -> Self
Sets the get_mut
field
Sourcepub const fn byte_stride(self, f: NdArrayByteStrideFn) -> Self
pub const fn byte_stride(self, f: NdArrayByteStrideFn) -> Self
Sets the byte_stride
field
Sourcepub const fn as_ptr(self, f: NdArrayAsPtrFn) -> Self
pub const fn as_ptr(self, f: NdArrayAsPtrFn) -> Self
Sets the as_ptr
field
Sourcepub const fn as_mut_ptr(self, f: NdArrayAsMutPtrFn) -> Self
pub const fn as_mut_ptr(self, f: NdArrayAsMutPtrFn) -> Self
Sets the as_mut_ptr
field
Sourcepub const fn build(self) -> NdArrayVTable
pub const fn build(self) -> NdArrayVTable
Builds the NdArrayVTable
from the current state of the builder.
§Panics
Panic if any of the required fields (len, get, as_ptr, iter_vtable) are None
.
Auto Trait Implementations§
impl Freeze for NdArrayVTableBuilder
impl RefUnwindSafe for NdArrayVTableBuilder
impl Send for NdArrayVTableBuilder
impl Sync for NdArrayVTableBuilder
impl Unpin for NdArrayVTableBuilder
impl UnwindSafe for NdArrayVTableBuilder
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