Solver

interface Solver: ExecutionContextAware, Any

Represents a Prolog Goal solver

Methods

solve

abstract fun solve(goal: Struct, maxDuration: TimeDuration): Sequence<Solution>

Solves the provided goal, returning lazily initialized sequence of solutions, optionally limiting computation maxDuration

Parameters

Name Description
goal: Struct
maxDuration: TimeDuration

ReturnValue

Name Description
Sequence<Solution>

solve

open fun solve(goal: Struct): Sequence<Solution>

Parameters

Name Description
goal: Struct

ReturnValue

Name Description
Sequence<Solution>

Extensions

solve

fun Solver.solve(maxDuration: TimeDuration, scopedContext: Scope.()->Struct): Sequence<Solution>

Receiver

Name Description
Solver

Parameters

Name Description
maxDuration: TimeDuration
scopedContext: Scope.()->Struct

ReturnValue

Name Description
Sequence<Solution>