class PermissionError: LogicError
Fields
Name | Description |
---|---|
val type: Struct
|
The error type structure |
val operation: Operation
|
the operation which caused the error |
val permission: Permission
|
the type of the tried permission |
val culprit: Term
|
Constructors
<init>
constructor(message: String?, cause: Throwable?, context: ExecutionContext, operation: Operation, permission: Permission, culprit: Term, extraData: Term?)
Parameters
Name | Description |
---|---|
message: String?
|
|
cause: Throwable?
|
|
context: ExecutionContext
|
|
operation: Operation
|
|
permission: Permission
|
|
culprit: Term
|
|
extraData: Term?
|
<init>
constructor(message: String?, cause: Throwable?, contexts: Array<ExecutionContext>, operation: Operation, permission: Permission, culprit: Term, extraData: Term?)
A permission error occurs when an attempt to perform a prohibited operation is made
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 |
operation: Operation
|
the operation which caused the error |
permission: Permission
|
the type of the tried permission |
culprit: Term
|
|
extraData: Term?
|
the possible extra data to be carried with the error |
Methods
updateContext
fun updateContext(newContext: ExecutionContext, index: Int): PermissionError
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 |
---|---|
PermissionError
|
updateLastContext
fun updateLastContext(newContext: ExecutionContext): PermissionError
Parameters
Name | Description |
---|---|
newContext: ExecutionContext
|
ReturnValue
Name | Description |
---|---|
PermissionError
|
pushContext
fun pushContext(newContext: ExecutionContext): PermissionError
Parameters
Name | Description |
---|---|
newContext: ExecutionContext
|
ReturnValue
Name | Description |
---|---|
PermissionError
|
CompanionObject
PermissionError
class PermissionError: LogicError
A permission error occurs when an attempt to perform a prohibited operation is made
Fields
Name | Description |
---|---|
const typeFunctor: String
|
The permission error Struct functor |
Methods
of
fun of(context: ExecutionContext, procedure: Signature, operation: Operation, permission: Permission, culprit: Term): PermissionError
Parameters
Name | Description |
---|---|
context: ExecutionContext
|
|
procedure: Signature
|
|
operation: Operation
|
|
permission: Permission
|
|
culprit: Term
|
ReturnValue
Name | Description |
---|---|
PermissionError
|
A permission error occurs when an attempt to perform a prohibited operation is made