Struct Global

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

The WebAssembly.Global() constructor creates a new Global object of the given type and value.

MDN documentation

Implementations

impl Global

fn new(global_descriptor: &Object, value: &JsValue) -> Result<Global, JsValue>

The WebAssembly.Global() constructor creates a new Global object of the given type and value.

MDN documentation

impl Global

fn value(&self) -> JsValue

The value prototype property of the WebAssembly.Global object returns the value of the global.

MDN documentation

impl Global

fn set_value(&self, value: &JsValue)

Trait Implementations

impl AsRef<Global> for Global

fn as_ref(&self) -> &Global

impl AsRef<JsValue> for Global

fn as_ref(&self) -> &JsValue

impl AsRef<Object> for Global

fn as_ref(&self) -> &Object

impl Clone for Global

fn clone(&self) -> Self

impl Debug for Global

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

impl Deref for Global

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

impl Eq for Global

impl ErasableGeneric for Global

type Repr = JsValue;

impl From<JsValue> for Global

fn from(obj: JsValue) -> Self

impl FromWasmAbi for Global

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

impl IntoJsGeneric for Global where Global: JsGeneric,

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

impl IntoWasmAbi for Global

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

impl JsCast for Global

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

impl LongRefFromWasmAbi for Global

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

impl OptionFromWasmAbi for Global

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

impl OptionIntoWasmAbi for Global

fn none() -> Self::Abi

impl PartialEq for Global

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

impl Promising for Global

type Resolution = Global;

impl RefFromWasmAbi for Global

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

impl StructuralPartialEq for Global

impl UpcastFrom<Global> for Global

impl WasmDescribe for Global

fn describe()

Auto Trait Implementations

impl Freeze for Global

impl RefUnwindSafe for Global

impl Send for Global

impl Sync for Global

impl Unpin for Global

impl UnsafeUnpin for Global

impl UnwindSafe for Global

Blanket Implementations

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

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

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

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

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

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

impl<T> From<T> for Global

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

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

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

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

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

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

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

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

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

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