SudoklifyAssembler

Creates a SudoklifyAssembler instance using a DSL-style function.

This function simplifies the creation of a SudoklifyAssembler by using a DSL-style syntax, allowing configuration and assembly in a concise and expressive manner.

Example:

val assembler = SudoklifyAssembler(schemas, spec)

Return

A SudoklifyAssembler instance configured with the provided parameters.

Parameters

schemas

The SudokuSchemas containing Sudoku schemas.

spec

The SudokuSpec specifying the puzzle's configuration.


fun <T> SudoklifyAssembler(schemas: SudokuSchemas, spec: SudokuSpec, block: SudoklifyAssembler.() -> T): T

Creates a SudoklifyAssembler instance using a DSL-style function with a configuration block.

This function simplifies the creation of a SudoklifyAssembler and immediately executes the provided block of code. This allows for a concise and expressive configuration of the assembler followed by immediate execution.

Example:

val sudoku = SudoklifyAssembler(schemas, spec) {
assembleSudoku()
}
println(sudoku)

Return

The result of executing the block on the SudoklifyAssembler instance.

Parameters

schemas

The SudokuSchemas containing Sudoku schemas.

spec

The SudokuSpec specifying the puzzle's configuration.

block

A block of code to be executed on the created SudoklifyAssembler instance.