pub trait GetMut2D: Get2D {
// Required method
fn try_get_mut_xy<T: ToPrimitive>(
&mut self,
x: T,
y: T,
) -> Result<&mut Self::Item, IndexError>;
// Provided methods
fn get_mut_xy<T: ToPrimitive>(&mut self, x: T, y: T) -> &mut Self::Item { ... }
fn get_mut_p<T: ToPrimitive, P: IntoTuple2<T>>(
&mut self,
p: P,
) -> &mut Self::Item { ... }
fn try_get_mut_p<T: ToPrimitive, P: IntoTuple2<T>>(
&mut self,
p: P,
) -> Result<&mut Self::Item, IndexError> { ... }
}Required Methods§
fn try_get_mut_xy<T: ToPrimitive>( &mut self, x: T, y: T, ) -> Result<&mut Self::Item, IndexError>
Provided Methods§
fn get_mut_xy<T: ToPrimitive>(&mut self, x: T, y: T) -> &mut Self::Item
fn get_mut_p<T: ToPrimitive, P: IntoTuple2<T>>( &mut self, p: P, ) -> &mut Self::Item
fn try_get_mut_p<T: ToPrimitive, P: IntoTuple2<T>>( &mut self, p: P, ) -> Result<&mut Self::Item, IndexError>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.
Implementations on Foreign Types§
Source§impl<D> GetMut2D for Vec<Vec<D>>
impl<D> GetMut2D for Vec<Vec<D>>
fn try_get_mut_xy<T: ToPrimitive>( &mut self, x: T, y: T, ) -> Result<&mut Self::Item, IndexError>
Source§impl<P, C> GetMut2D for ImageBuffer<P, C>
Available on crate feature image only.
impl<P, C> GetMut2D for ImageBuffer<P, C>
Available on crate feature
image only.fn try_get_mut_xy<T: ToPrimitive>( &mut self, x: T, y: T, ) -> Result<&mut Self::Item, IndexError>
Source§impl<S: DataMut> GetMut2D for ArrayBase<S, Ix2>
Available on crate feature ndarray only.
impl<S: DataMut> GetMut2D for ArrayBase<S, Ix2>
Available on crate feature
ndarray only.