Warning

abstract class Warning: ResolutionException

Base class for Prolog warnings

Constructors

<init>

constructor(message: String?, cause: Throwable?, context: ExecutionContext)

Parameters

Name Description
message: String?
cause: Throwable?
context: ExecutionContext

<init>

constructor(message: String?, cause: Throwable?, contexts: Array<ExecutionContext>)

Base class for Prolog warnings

Parameters

Name Description
message: String?

the detail message string.

cause: Throwable?

the cause of this exception.

contexts: Array<ExecutionContext>

a stack of contexts localising the exception

Methods

updateContext

abstract fun updateContext(newContext: ExecutionContext, index: Int): Warning

Creates a new exception instance with the context with in position index updated to newContext. Subclasses should override this method and return the correct instance.

Parameters

Name Description
newContext: ExecutionContext
index: Int

ReturnValue

Name Description
Warning

updateLastContext

abstract fun updateLastContext(newContext: ExecutionContext): Warning

Parameters

Name Description
newContext: ExecutionContext

ReturnValue

Name Description
Warning

pushContext

abstract fun pushContext(newContext: ExecutionContext): Warning

Parameters

Name Description
newContext: ExecutionContext

ReturnValue

Name Description
Warning