Package webb.shared.dtos.puzzle.created
Class CreatePuzzleLevelDTO
java.lang.Object
webb.shared.dtos.puzzle.created.CreatePuzzleLevelDTO
- Direct Known Subclasses:
UpdatePuzzleLevelDTO
Represents a puzzle from the JSON file.
Modified from: https://cs.plu.edu/courses/protected/cs390/2023s/project/iteration2.html
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
CreatePuzzleLevelDTO
public CreatePuzzleLevelDTO(List<List<CellDTO>> regions, List<CellDTO> solution, int gridSize, int numStars) Constructor for CreatePuzzleLevelDTO- Parameters:
regions- the regions of the puzzle as a list of CellDTOsolution- the solution to the puzzle as a list of CellDTOgridSize- the size of the gridnumStars- the number of stars per region
-
-
Method Details
-
getRegions
- Returns:
- the regions of the puzzle as a list of Cells
-
getSolution
- Returns:
- the solution to the puzzle as a list of Cells
-
getGridSize
public int getGridSize()- Returns:
- the size of the grid
-
getNumStars
public int getNumStars()- Returns:
- the number of stars per region
-
getTotalStars
public int getTotalStars()- Returns:
- the total number of stars in the puzzle
-
toString
-