class Exception
pub class Exception :: [Error]
Conforms to Error.
A ready-made Error that carries a message.
throw Exception("…");, and Exception("…", cause: e) for the error it wraps. The fields
are text and inner; the methods message() and cause() return them.
Fields
pub text: string
What message() returns.
pub inner: ?Error = null
The error this one wraps, if any: what cause() returns.
Methods
pub static fn new(message: string, cause: ?Error = null): Exception
Creates an exception with message and, optionally, the error it wraps.
pub fn message(): string
pub fn cause(): ?Error