Package it.unibo.tuprolog.solve.exception.error

Types

Link copied to clipboard
class DomainError(    message: String? = null,     cause: Throwable? = null,     val contexts: Array<ExecutionContext>,     val expectedDomain: DomainError.Expected,     val culprit: <ERROR CLASS>,     val extraData: <ERROR CLASS>? = null) : LogicError

The domain error occurs when something has the correct type but the value is not admissible

Link copied to clipboard
object ErrorUtils

Prolog error handling utilities

Link copied to clipboard
class EvaluationError(    message: String? = null,     cause: Throwable? = null,     val contexts: Array<ExecutionContext>,     val errorType: EvaluationError.Type,     val extraData: <ERROR CLASS>? = null) : LogicError

The evaluation error occurs when some problem occurs in evaluating an arithmetic expression

Link copied to clipboard
class ExistenceError(    message: String? = null,     cause: Throwable? = null,     val contexts: Array<ExecutionContext>,     val expectedObject: ExistenceError.ObjectType,     val culprit: <ERROR CLASS>,     val extraData: <ERROR CLASS>? = null) : LogicError

The existence error occurs when an object on which an operation is to be performed does not exist

Link copied to clipboard
class InstantiationError(    message: String? = null,     cause: Throwable? = null,     val contexts: Array<ExecutionContext>,     val culprit: <ERROR CLASS> = Var.anonymous(),     val extraData: <ERROR CLASS>? = null) : LogicError

The instantiation error occurs when some Term is a Variable, and it should not

Link copied to clipboard
class MessageError : LogicError

The MessageError is used whenever no other LogicError instance is suitable for representing the error

Link copied to clipboard
class PermissionError(    message: String? = null,     cause: Throwable? = null,     val contexts: Array<ExecutionContext>,     val operation: PermissionError.Operation,     val permission: PermissionError.Permission,     val culprit: <ERROR CLASS>,     val extraData: <ERROR CLASS>? = null) : LogicError

A permission error occurs when an attempt to perform a prohibited operation is made

Link copied to clipboard
class RepresentationError(    message: String? = null,     cause: Throwable? = null,     val contexts: Array<ExecutionContext>,     val limit: RepresentationError.Limit,     val extraData: <ERROR CLASS>? = null) : LogicError

A representation error occurs when an implementation limit has been breached

Link copied to clipboard
class SyntaxError(    message: String? = null,     cause: Throwable? = null,     val contexts: Array<ExecutionContext>,     val extraData: <ERROR CLASS>? = null) : LogicError
Link copied to clipboard
class SystemError(    message: String? = null,     cause: Throwable? = null,     val contexts: Array<ExecutionContext>,     val extraData: <ERROR CLASS>? = null) : LogicError

The system error occurs when an internal problem occurred and if not caught, it will halt inferential machine

Link copied to clipboard
class TypeError(    message: String? = null,     cause: Throwable? = null,     val contexts: Array<ExecutionContext>,     val expectedType: TypeError.Expected,     val culprit: <ERROR CLASS>,     val extraData: <ERROR CLASS>? = null) : LogicError

The type error occurs when something is not of Expected type