Enum swipl::result::PrologError
source · pub enum PrologError {
Failure,
Exception,
}
Expand description
A prolog error.
This is either a failure or an exception. In case of an exception, whowever returned the exception was also supposed to raise an exception on the context.
Variants§
Implementations§
source§impl PrologError
impl PrologError
sourcepub fn is_failure(&self) -> bool
pub fn is_failure(&self) -> bool
Returns true if this error is a failure.
sourcepub fn is_exception(&self) -> bool
pub fn is_exception(&self) -> bool
Returns true if this error is an exception.
Trait Implementations§
source§impl Debug for PrologError
impl Debug for PrologError
source§impl Display for PrologError
impl Display for PrologError
source§impl Error for PrologError
impl Error for PrologError
1.30.0 · source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
1.0.0 · source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
source§impl From<PrologException> for PrologError
impl From<PrologException> for PrologError
source§fn from(_val: PrologException) -> PrologError
fn from(_val: PrologException) -> PrologError
Converts to this type from the input type.
source§impl PartialEq for PrologError
impl PartialEq for PrologError
source§fn eq(&self, other: &PrologError) -> bool
fn eq(&self, other: &PrologError) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for PrologError
impl StructuralEq for PrologError
impl StructuralPartialEq for PrologError
Auto Trait Implementations§
impl RefUnwindSafe for PrologError
impl Send for PrologError
impl Sync for PrologError
impl Unpin for PrologError
impl UnwindSafe for PrologError
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more