Struct AggregateError

#[repr(transparent)]
pub struct AggregateError { /* private fields */ }

The AggregateError object represents an error when several errors need to be wrapped in a single error. It is thrown when multiple errors need to be reported by an operation, for example by Promise::any, when all promises passed to it reject.

AggregateError is a subclass of Error.

MDN documentation

Implementations

impl AggregateError

fn new_with_message(errors: &[JsValue], message: &str) -> AggregateError

Creates a new AggregateError from the given iterable of errors with a human-readable description of the aggregate error.

MDN documentation

impl AggregateError

fn new_with_options(errors: &[JsValue], message: &str, options: &ErrorOptions) -> AggregateError

Creates a new AggregateError from the given iterable of errors, a human-readable description of the aggregate error, and an ErrorOptions dictionary whose cause property indicates the original cause of the error.

MDN documentation

impl AggregateError

fn new(errors: &[JsValue]) -> AggregateError

Creates a new AggregateError from the given iterable of errors.

MDN documentation

impl AggregateError

fn errors(&self) -> Array

The errors property of an AggregateError instance is an array representing the errors that were aggregated.

MDN documentation

Trait Implementations

impl AsRef<AggregateError> for AggregateError

fn as_ref(&self) -> &AggregateError

impl AsRef<Error> for AggregateError

fn as_ref(&self) -> &Error

impl AsRef<JsValue> for AggregateError

fn as_ref(&self) -> &JsValue

impl AsRef<Object> for AggregateError

fn as_ref(&self) -> &Object

impl Clone for AggregateError

fn clone(&self) -> Self

impl Debug for AggregateError

fn fmt(&self, f: &mut Formatter<'_>) -> Result

impl Deref for AggregateError

type Target = Error;
fn deref(&self) -> &Error

impl Eq for AggregateError

impl ErasableGeneric for AggregateError

type Repr = JsValue;

impl From<JsValue> for AggregateError

fn from(obj: JsValue) -> Self

impl FromWasmAbi for AggregateError

type Abi = <JsValue as FromWasmAbi>::Abi;
unsafe fn from_abi(js: Self::Abi) -> Self

impl IntoJsGeneric for AggregateError where AggregateError: JsGeneric,

type JsCanon = AggregateError;
fn to_js(self) -> AggregateError

impl IntoWasmAbi for AggregateError

type Abi = <JsValue as IntoWasmAbi>::Abi;
fn into_abi(self) -> Self::Abi

impl JsCast for AggregateError

fn instanceof(val: &JsValue) -> bool
fn unchecked_from_js(val: JsValue) -> Self
fn unchecked_from_js_ref(val: &JsValue) -> &Self

impl LongRefFromWasmAbi for AggregateError

type Abi = <JsValue as LongRefFromWasmAbi>::Abi;
type Anchor = AggregateError;
unsafe fn long_ref_from_abi(js: Self::Abi) -> Self::Anchor

impl OptionFromWasmAbi for AggregateError

fn is_none(abi: &Self::Abi) -> bool

impl OptionIntoWasmAbi for AggregateError

fn none() -> Self::Abi

impl PartialEq for AggregateError

fn eq(&self, other: &Self) -> bool

impl Promising for AggregateError

type Resolution = AggregateError;

impl RefFromWasmAbi for AggregateError

type Abi = <JsValue as RefFromWasmAbi>::Abi;
type Anchor = ManuallyDrop<AggregateError>;
unsafe fn ref_from_abi(js: Self::Abi) -> Self::Anchor

impl StructuralPartialEq for AggregateError

impl UpcastFrom<AggregateError> for AggregateError

impl WasmDescribe for AggregateError

fn describe()

Auto Trait Implementations

impl Freeze for AggregateError

impl RefUnwindSafe for AggregateError

impl Send for AggregateError

impl Sync for AggregateError

impl Unpin for AggregateError

impl UnsafeUnpin for AggregateError

impl UnwindSafe for AggregateError

Blanket Implementations

impl<P, T> Receiver for AggregateError where P: Deref<Target = T> + ?Sized, T: ?Sized,

impl<S, T> Upcast<T> for AggregateError where T: UpcastFrom<S> + ?Sized, S: ?Sized,

impl<T> Any for AggregateError where T: 'static + ?Sized,

impl<T> Borrow<T> for AggregateError where T: ?Sized,

impl<T> BorrowMut<T> for AggregateError where T: ?Sized,

impl<T> CloneToUninit for AggregateError where T: Clone,

impl<T> From<T> for AggregateError

impl<T> JsGeneric for AggregateError where T: ErasableGeneric<Repr = JsValue> + UpcastFrom<T> + Upcast<JsValue> + JsCast + 'static,

impl<T> ReturnWasmAbi for AggregateError where T: IntoWasmAbi,

impl<T> ToOwned for AggregateError where T: Clone,

impl<T> TryFromJsValue for AggregateError where T: JsCast,

impl<T> VectorFromWasmAbi for AggregateError where T: ErasableGeneric<Repr = JsValue> + WasmDescribe,

impl<T> VectorIntoWasmAbi for AggregateError where T: ErasableGeneric<Repr = JsValue> + WasmDescribe,

impl<T> VectorRefIntoWasmAbi for AggregateError where &'a T: for<'a> Into<JsValue>,

impl<T, U> Into<U> for AggregateError where U: From<T>,

impl<T, U> TryFrom<U> for AggregateError where U: Into<T>,

impl<T, U> TryInto<U> for AggregateError where U: TryFrom<T>,