pub enum Error {
Show 27 variants
IndexSize,
NotFound,
HierarchyRequest,
WrongDocument,
InvalidCharacter,
NotSupported,
InUseAttribute,
InvalidState,
Syntax,
Namespace,
InvalidAccess,
Security,
Network,
Abort,
Timeout,
InvalidNodeType,
DataClone,
NoModificationAllowed,
QuotaExceeded,
TypeMismatch,
InvalidModification,
NotReadable,
Data,
Operation,
Type(String),
Range(String),
JSFailed,
}
Expand description
DOM exceptions that can be thrown by a native DOM method.
Variants§
IndexSize
IndexSizeError DOMException
NotFound
NotFoundError DOMException
HierarchyRequest
HierarchyRequestError DOMException
WrongDocument
WrongDocumentError DOMException
InvalidCharacter
InvalidCharacterError DOMException
NotSupported
NotSupportedError DOMException
InUseAttribute
InUseAttributeError DOMException
InvalidState
InvalidStateError DOMException
Syntax
SyntaxError DOMException
Namespace
NamespaceError DOMException
InvalidAccess
InvalidAccessError DOMException
Security
SecurityError DOMException
Network
NetworkError DOMException
Abort
AbortError DOMException
Timeout
TimeoutError DOMException
InvalidNodeType
InvalidNodeTypeError DOMException
DataClone
DataCloneError DOMException
NoModificationAllowed
NoModificationAllowedError DOMException
QuotaExceeded
QuotaExceededError DOMException
TypeMismatch
TypeMismatchError DOMException
InvalidModification
InvalidModificationError DOMException
NotReadable
NotReadableError DOMException
Data
DataError DOMException
Operation
OperationError DOMException
Type(String)
TypeError JavaScript Error
Range(String)
RangeError JavaScript Error
JSFailed
A JavaScript exception is already pending.
Implementations§
source§impl Error
impl Error
sourcepub unsafe fn to_jsval(
self,
cx: *mut JSContext,
global: &GlobalScope,
rval: MutableHandleValue<'_>,
)
pub unsafe fn to_jsval( self, cx: *mut JSContext, global: &GlobalScope, rval: MutableHandleValue<'_>, )
Convert this error value to a JS value, consuming it in the process.
Trait Implementations§
source§impl From<BluetoothError> for Error
impl From<BluetoothError> for Error
source§fn from(error: BluetoothError) -> Self
fn from(error: BluetoothError) -> Self
source§impl From<RulesMutateError> for Error
impl From<RulesMutateError> for Error
source§fn from(other: RulesMutateError) -> Self
fn from(other: RulesMutateError) -> Self
source§impl MallocSizeOf for Error
impl MallocSizeOf for Error
source§fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
Auto Trait Implementations§
impl Freeze for Error
impl RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnwindSafe for Error
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
source§impl<T> Filterable for T
impl<T> Filterable for T
source§fn filterable(
self,
filter_name: &'static str,
) -> RequestFilterDataProvider<T, fn(_: DataRequest<'_>) -> bool>
fn filterable( self, filter_name: &'static str, ) -> RequestFilterDataProvider<T, fn(_: DataRequest<'_>) -> bool>
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more