SudokuFX
Loading...
Searching...
No Matches
fr.softsf.sudokufx.common.enums.DifficultyLevel Enum Reference

Defines the difficulty levels of a Sudoku grid and provides conversions between enum values and their numeric/byte representations. More...

+ Collaboration diagram for fr.softsf.sudokufx.common.enums.DifficultyLevel:

Public Member Functions

int toGridNumber ()
 Converts this difficulty level to its numeric representation.
 

Static Public Member Functions

static DifficultyLevel fromGridByte (byte number)
 Resolves a DifficultyLevel from its byte representation.
 

Public Attributes

 DIFFICULT
 
 EASY
 
 MEDIUM
 

Static Private Attributes

static final Logger LOG = LoggerFactory.getLogger(DifficultyLevel.class)
 

Detailed Description

Defines the difficulty levels of a Sudoku grid and provides conversions between enum values and their numeric/byte representations.

Member Function Documentation

◆ fromGridByte()

static DifficultyLevel fr.softsf.sudokufx.common.enums.DifficultyLevel.fromGridByte ( byte number)
static

Resolves a DifficultyLevel from its byte representation.

Parameters
numberthe byte value (1, 2, 3)
Returns
the corresponding DifficultyLevel
Exceptions
IllegalArgumentExceptionif the value does not match any level

◆ toGridNumber()

int fr.softsf.sudokufx.common.enums.DifficultyLevel.toGridNumber ( )

Converts this difficulty level to its numeric representation.

Returns
1 for EASY, 2 for MEDIUM, 3 for DIFFICULT

Member Data Documentation

◆ DIFFICULT

fr.softsf.sudokufx.common.enums.DifficultyLevel.DIFFICULT

◆ EASY

fr.softsf.sudokufx.common.enums.DifficultyLevel.EASY

◆ LOG

final Logger fr.softsf.sudokufx.common.enums.DifficultyLevel.LOG = LoggerFactory.getLogger(DifficultyLevel.class)
staticprivate

◆ MEDIUM

fr.softsf.sudokufx.common.enums.DifficultyLevel.MEDIUM

The documentation for this enum was generated from the following file: