Struct rudoku_core::sudoku::Sudoku
source · [−]pub struct Sudoku { /* private fields */ }
Implementations
sourceimpl Sudoku
impl Sudoku
pub fn new(n: usize) -> (Self, Self)
pub fn decimate(&mut self, n: usize)
pub fn solve(&mut self, r: usize, c: usize) -> i32
pub fn fill(&mut self, r: usize, c: usize) -> bool
pub fn solved(&self) -> bool
pub fn check_all(&self) -> bool
pub fn check(&self, r: usize, c: usize) -> bool
pub fn count(&self, val: SudokuValue) -> usize
pub fn get_row(&self, r: usize) -> Option<[&SudokuValue; 9]>
pub fn get_column(&self, c: usize) -> Option<[&SudokuValue; 9]>
pub fn get_square(&self, r: usize, c: usize) -> Option<[&SudokuValue; 9]>
pub fn get(&self, r: usize, c: usize) -> Option<&SudokuValue>
pub fn set(&mut self, r: usize, c: usize, val: SudokuValue)
Trait Implementations
sourceimpl Ord for Sudoku
impl Ord for Sudoku
sourceimpl PartialOrd<Sudoku> for Sudoku
impl PartialOrd<Sudoku> for Sudoku
sourcefn partial_cmp(&self, other: &Sudoku) -> Option<Ordering>
fn partial_cmp(&self, other: &Sudoku) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
1.0.0 · sourcefn lt(&self, other: &Rhs) -> bool
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
impl Copy for Sudoku
impl Eq for Sudoku
impl StructuralEq for Sudoku
impl StructuralPartialEq for Sudoku
Auto Trait Implementations
impl RefUnwindSafe for Sudoku
impl Send for Sudoku
impl Sync for Sudoku
impl Unpin for Sudoku
impl UnwindSafe for Sudoku
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more