commonMain.it.unibo.tuprolog.solve.stdlib.CommonRules.kt Maven / Gradle / Ivy
package it.unibo.tuprolog.solve.stdlib
import it.unibo.tuprolog.solve.ExecutionContext
import it.unibo.tuprolog.solve.rule.RuleWrapper
import it.unibo.tuprolog.solve.stdlib.rule.Append
import it.unibo.tuprolog.solve.stdlib.rule.Arrow
import it.unibo.tuprolog.solve.stdlib.rule.Member
import it.unibo.tuprolog.solve.stdlib.rule.Not
import it.unibo.tuprolog.solve.stdlib.rule.Once
import it.unibo.tuprolog.solve.stdlib.rule.Semicolon
import it.unibo.tuprolog.theory.Theory
object CommonRules {
val wrappers: Sequence> = sequenceOf(
Not,
Arrow,
Semicolon.If.Then,
Semicolon.If.Else,
Semicolon.Or.Left,
Semicolon.Or.Right,
Member.Base,
Member.Recursive,
Append.Base,
Append.Recursive,
Once
)
val theory: Theory
get() = Theory.indexedOf(wrappers.map { it.wrappedImplementation })
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy