Package-level declarations
Types
Skeletal implementation of Termificator, providing the type-dispatch machinery (termify) and a library of protected handleXxxAsYyy conversion functions that subclasses register (via handleType) to implement Termificator.default/Termificator.legacy and any other custom conversion policy.
Root mixin of the Prolog DSL scope hierarchy: extends Scope (so every term-building factory method it exposes is directly available) with a termificator and the toTerm extension it powers, letting every other mixin in the hierarchy (see MinimalLogicProgrammingScope, LogicProgrammingScopeWithOperators, ...) accept a plain Any wherever a Term is expected.
Full term-construction scope of :dsl-core's Prolog DSL: composes every mixin this module defines — MinimalLogicProgrammingScope (structs, lists, clauses), LogicProgrammingScopeWithSubstitutions, LogicProgrammingScopeWithPrologStandardLibrary, LogicProgrammingScopeWithOperators and LogicProgrammingScopeWithVariables — into a single receiver type, self-referential (each mixin's own BaseLogicProgrammingScope type parameter is bound back to LogicProgrammingScope itself) so that BaseLogicProgrammingScope.newScope/scope/rule/fact/... all keep resolving to this same, richest type.
Adds infix/operator builders mirroring Prolog's own arithmetic, relational and logical operators, so that Structs (and Rules, for if/impliedBy) can be written as Kotlin expressions instead of nested BaseLogicProgrammingScope.toTerm/structOf calls:
Adds one builder per predicate of (roughly) the ISO Prolog standard library — plus a handful of well-known de-facto standard ones (assert, findall, member, ...) — so common goals can be written as ordinary Kotlin function/property calls instead of structOf("member", item, list)-style boilerplate:
Adds builders and accessors for Substitutions, so a Var to value pair can be written directly ("X" to 1, mirroring Kotlin's own kotlin.to for Pairs) and a built Substitution can be queried by a plain Var-like value instead of a variable name/Var pair:
Adds fresh-variable creation to the scope by mixing in VariablesProvider (delegating to variablesProvider), so idiomatic single-letter variables (A, B, C, ... from VariablesProvider) and by-delegated ones (val x by variablesProvider) are available directly inside a logicProgramming block, alongside every other BaseLogicProgrammingScope mixin.
Core term/clause-building mixin of the Prolog DSL: overloads it.unibo.tuprolog.core.Scope's own structOf/tupleOf/logicListOf/... factory methods to accept plain Any arguments (auto-toTerm-ed), adds the "calling a String" shorthand for building Structs, and adds scoped clause builders (rule/fact/directive/clause) that isolate each clause's variables in their own newScope.
Functions
Entry point of the Prolog term-construction DSL: runs function with a fresh, empty LogicProgrammingScope as its receiver, and returns whatever function returns. This is the idiomatic way of building it.unibo.tuprolog.core.Terms, it.unibo.tuprolog.core.Clauses and the like through the DSL, instead of instantiating a LogicProgrammingScope by hand:
Shorthand for logicProgramming.
Deprecated alias of logicProgramming/lp; kept only for backwards compatibility.