SudokuUtilities class

Provides various functions related to using the Sudoku Solver and Generator classes or handling the Sudoku puzzles.

Utility class which shouldn't be instantiated.

Constructors

SudokuUtilities()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

copySudoku(List<List<int>> sudoku) List<List<int>>
Returns an identical copy of the provided sudoku.
hasUniqueSolution(List<List<int>> sudoku) bool
Returns true if the sudoku has only 1 solution.
isSolved(List<List<int>> sudoku) bool
Returns true if the configuration of the sudoku is valid and there are no 0s/empty squares.
isValidConfiguration(List<List<int?>> sudoku) bool
Returns true if the configuration of the sudoku follows the rules of Sudoku.
makeNullSafe(List<List<int?>> sudoku) List<List<int>>
Returns a null safe copy of provided sudoku to make it usable.
printSudoku(List<List<int>> sudoku) → void
Prints the sudoku in a readable format to the console. Zeroes are represented as -.
to1D(List<List<int>> sudoku) List<int>
Returns a copy of the provided sudoku as a 1 Dimensional List.
to2D(List<int> sudoku) List<List<int>>
Returns a copy of the provided sudoku as a 2 Dimensional List which is the standard format.