All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.it.unibo.tuprolog.datalog.exception.InvalidLiteralException.kt Maven / Gradle / Ivy

There is a newer version: 1.0.4
Show newest version
package it.unibo.tuprolog.datalog.exception

import it.unibo.tuprolog.core.Clause
import it.unibo.tuprolog.core.Term
import it.unibo.tuprolog.core.exception.TuPrologException

@Suppress("MemberVisibilityCanBePrivate")
class InvalidLiteralException : TuPrologException {
    val literal: Term

    val clause: Clause?

    constructor(literal: Term, clause: Clause?, cause: Throwable? = null) : super(
        message = "Invalid literal in clause${clause?.let { " $it" } ?: ""}: $literal",
        cause = cause,
    ) {
        this.literal = literal
        this.clause = clause
    }

    constructor(literal: Term, cause: Throwable? = null) : this(literal, null, cause)
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy