pub struct JSException { /* private fields */ }Expand description
A wrapper for a JSValue that contains an exception.
Implementations§
Source§impl JSException
impl JSException
Sourcepub const fn underlying_value(&self) -> &JSValue
pub const fn underlying_value(&self) -> &JSValue
Return the underlying value backing the exception.
Sourcepub fn name(&self) -> Result<JSString, JSException>
pub fn name(&self) -> Result<JSString, JSException>
Return the name of the exception. This is the value of the name
property on the exception object.
Trait Implementations§
Source§impl Debug for JSException
impl Debug for JSException
Source§impl Display for JSException
impl Display for JSException
Source§impl Error for JSException
impl Error for JSException
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns 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<JSException> for JSValueRef
impl From<JSException> for JSValueRef
Source§fn from(value: JSException) -> Self
fn from(value: JSException) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for JSException
impl RefUnwindSafe for JSException
impl !Send for JSException
impl !Sync for JSException
impl Unpin for JSException
impl UnwindSafe for JSException
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