Returns an iterator over all elements of the matrix in row-major order. ``` # #[macro_use] extern crate rustml; use rustml::*; # fn main() { let m = mat![ 1.0, 1.5; 2.0, 2.5 ]; let mut i = m.values(); assert_eq!(i.next().unwrap(), &1.0); assert_eq!(i.next().unwrap(), &1.5); assert_eq!(i.next().unwrap(), &2.0); # } ```
(&self)
| 409 | /// # } |
| 410 | /// ``` |
| 411 | pub fn values(&self) -> Iter<T> { |
| 412 | self.data.iter() |
| 413 | } |
| 414 | |
| 415 | /// Returns a mutable iterator over all elements of the matrix in row-major order. |
| 416 | /// |