Struct vec2d::Vec2D
[−]
[src]
pub struct Vec2D<T> { // some fields omitted }
Container for 2D data
Methods
impl<Elem: Copy> Vec2D<Elem>
[src]
fn from_example(size: Size, example: &Elem) -> Vec2D<Elem>
Create a Vec2D with the given size
. All elements are
initialized as copies of the example
element.
fn from_vec(size: Size, src: Vec<Elem>) -> Option<Vec2D<Elem>>
Create a Vec2D with the given size
. The contents are set to
src
. None is returned if the size
does not match the
length of src
.
fn rect_iter_mut<'a>(&'a mut self, rect: Rect) -> Option<RectIterMut<'a, Elem>>
Create a mutable iterator over a rectangular region of the
Vec2D. None is returned if the given rect
does not fit
entirely within the Vec2D.
Trait Implementations
impl<T: Debug> Debug for Vec2D<T>
[src]
impl<T: Clone> Clone for Vec2D<T>
[src]
fn clone(&self) -> Vec2D<T>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more