Struct web_sys::MessageEvent
source · #[repr(transparent)]pub struct MessageEvent { /* private fields */ }
Expand description
The MessageEvent
object
This API requires the following crate features to be activated: MessageEvent
Implementations§
source§impl MessageEvent
impl MessageEvent
source§impl MessageEvent
impl MessageEvent
sourcepub fn new_with_event_init_dict(
type_: &str,
event_init_dict: &MessageEventInit
) -> Result<MessageEvent, JsValue>
pub fn new_with_event_init_dict(
type_: &str,
event_init_dict: &MessageEventInit
) -> Result<MessageEvent, JsValue>
The new MessageEvent(..)
constructor, creating a new instance of MessageEvent
This API requires the following crate features to be activated: MessageEvent
, MessageEventInit
source§impl MessageEvent
impl MessageEvent
sourcepub fn init_message_event(&self, type_: &str)
pub fn init_message_event(&self, type_: &str)
The initMessageEvent()
method
This API requires the following crate features to be activated: MessageEvent
source§impl MessageEvent
impl MessageEvent
sourcepub fn init_message_event_with_bubbles(&self, type_: &str, bubbles: bool)
pub fn init_message_event_with_bubbles(&self, type_: &str, bubbles: bool)
The initMessageEvent()
method
This API requires the following crate features to be activated: MessageEvent
source§impl MessageEvent
impl MessageEvent
sourcepub fn init_message_event_with_bubbles_and_cancelable(
&self,
type_: &str,
bubbles: bool,
cancelable: bool
)
pub fn init_message_event_with_bubbles_and_cancelable(
&self,
type_: &str,
bubbles: bool,
cancelable: bool
)
The initMessageEvent()
method
This API requires the following crate features to be activated: MessageEvent
source§impl MessageEvent
impl MessageEvent
source§impl MessageEvent
impl MessageEvent
source§impl MessageEvent
impl MessageEvent
sourcepub fn init_message_event_with_bubbles_and_cancelable_and_data_and_origin_and_last_event_id(
&self,
type_: &str,
bubbles: bool,
cancelable: bool,
data: &JsValue,
origin: &str,
last_event_id: &str
)
pub fn init_message_event_with_bubbles_and_cancelable_and_data_and_origin_and_last_event_id(
&self,
type_: &str,
bubbles: bool,
cancelable: bool,
data: &JsValue,
origin: &str,
last_event_id: &str
)
The initMessageEvent()
method
This API requires the following crate features to be activated: MessageEvent
source§impl MessageEvent
impl MessageEvent
sourcepub fn init_message_event_with_bubbles_and_cancelable_and_data_and_origin_and_last_event_id_and_opt_window(
&self,
type_: &str,
bubbles: bool,
cancelable: bool,
data: &JsValue,
origin: &str,
last_event_id: &str,
source: Option<&Window>
)
pub fn init_message_event_with_bubbles_and_cancelable_and_data_and_origin_and_last_event_id_and_opt_window(
&self,
type_: &str,
bubbles: bool,
cancelable: bool,
data: &JsValue,
origin: &str,
last_event_id: &str,
source: Option<&Window>
)
The initMessageEvent()
method
This API requires the following crate features to be activated: MessageEvent
, Window
source§impl MessageEvent
impl MessageEvent
sourcepub fn init_message_event_with_bubbles_and_cancelable_and_data_and_origin_and_last_event_id_and_opt_message_port(
&self,
type_: &str,
bubbles: bool,
cancelable: bool,
data: &JsValue,
origin: &str,
last_event_id: &str,
source: Option<&MessagePort>
)
pub fn init_message_event_with_bubbles_and_cancelable_and_data_and_origin_and_last_event_id_and_opt_message_port(
&self,
type_: &str,
bubbles: bool,
cancelable: bool,
data: &JsValue,
origin: &str,
last_event_id: &str,
source: Option<&MessagePort>
)
The initMessageEvent()
method
This API requires the following crate features to be activated: MessageEvent
, MessagePort
source§impl MessageEvent
impl MessageEvent
sourcepub fn init_message_event_with_bubbles_and_cancelable_and_data_and_origin_and_last_event_id_and_opt_service_worker(
&self,
type_: &str,
bubbles: bool,
cancelable: bool,
data: &JsValue,
origin: &str,
last_event_id: &str,
source: Option<&ServiceWorker>
)
pub fn init_message_event_with_bubbles_and_cancelable_and_data_and_origin_and_last_event_id_and_opt_service_worker(
&self,
type_: &str,
bubbles: bool,
cancelable: bool,
data: &JsValue,
origin: &str,
last_event_id: &str,
source: Option<&ServiceWorker>
)
The initMessageEvent()
method
This API requires the following crate features to be activated: MessageEvent
, ServiceWorker
source§impl MessageEvent
impl MessageEvent
source§impl MessageEvent
impl MessageEvent
source§impl MessageEvent
impl MessageEvent
sourcepub fn last_event_id(&self) -> String
pub fn last_event_id(&self) -> String
The lastEventId
getter
This API requires the following crate features to be activated: MessageEvent
Trait Implementations§
source§impl AsRef<Event> for MessageEvent
impl AsRef<Event> for MessageEvent
source§impl AsRef<JsValue> for MessageEvent
impl AsRef<JsValue> for MessageEvent
source§impl AsRef<Object> for MessageEvent
impl AsRef<Object> for MessageEvent
source§impl Clone for MessageEvent
impl Clone for MessageEvent
source§fn clone(&self) -> MessageEvent
fn clone(&self) -> MessageEvent
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for MessageEvent
impl Debug for MessageEvent
source§impl From<JsValue> for MessageEvent
impl From<JsValue> for MessageEvent
source§fn from(obj: JsValue) -> MessageEvent
fn from(obj: JsValue) -> MessageEvent
source§impl From<MessageEvent> for Event
impl From<MessageEvent> for Event
source§fn from(obj: MessageEvent) -> Event
fn from(obj: MessageEvent) -> Event
source§impl From<MessageEvent> for JsValue
impl From<MessageEvent> for JsValue
source§fn from(obj: MessageEvent) -> JsValue
fn from(obj: MessageEvent) -> JsValue
source§impl From<MessageEvent> for Object
impl From<MessageEvent> for Object
source§fn from(obj: MessageEvent) -> Object
fn from(obj: MessageEvent) -> Object
source§impl FromWasmAbi for MessageEvent
impl FromWasmAbi for MessageEvent
source§impl<'a> IntoWasmAbi for &'a MessageEvent
impl<'a> IntoWasmAbi for &'a MessageEvent
source§impl IntoWasmAbi for MessageEvent
impl IntoWasmAbi for MessageEvent
source§impl JsCast for MessageEvent
impl JsCast for MessageEvent
source§fn instanceof(val: &JsValue) -> bool
fn instanceof(val: &JsValue) -> bool
instanceof
check to see whether the JsValue
provided is an instance of this type. Read moresource§fn unchecked_from_js(val: JsValue) -> Self
fn unchecked_from_js(val: JsValue) -> Self
source§fn unchecked_from_js_ref(val: &JsValue) -> &Self
fn unchecked_from_js_ref(val: &JsValue) -> &Self
source§fn is_instance_of<T>(&self) -> boolwhere
T: JsCast,
fn is_instance_of<T>(&self) -> boolwhere
T: JsCast,
T
. Read moresource§fn dyn_into<T>(self) -> Result<T, Self>where
T: JsCast,
fn dyn_into<T>(self) -> Result<T, Self>where
T: JsCast,
T
. Read moresource§fn dyn_ref<T>(&self) -> Option<&T>where
T: JsCast,
fn dyn_ref<T>(&self) -> Option<&T>where
T: JsCast,
T
. Read moresource§fn unchecked_into<T>(self) -> Twhere
T: JsCast,
fn unchecked_into<T>(self) -> Twhere
T: JsCast,
source§impl OptionFromWasmAbi for MessageEvent
impl OptionFromWasmAbi for MessageEvent
source§impl<'a> OptionIntoWasmAbi for &'a MessageEvent
impl<'a> OptionIntoWasmAbi for &'a MessageEvent
source§impl OptionIntoWasmAbi for MessageEvent
impl OptionIntoWasmAbi for MessageEvent
source§impl RefFromWasmAbi for MessageEvent
impl RefFromWasmAbi for MessageEvent
§type Abi = <JsValue as RefFromWasmAbi>::Abi
type Abi = <JsValue as RefFromWasmAbi>::Abi
Self
are recovered from.§type Anchor = ManuallyDrop<MessageEvent>
type Anchor = ManuallyDrop<MessageEvent>
Self
for the duration of the
invocation of the function that has an &Self
parameter. This is
required to ensure that the lifetimes don’t persist beyond one function
call, and so that they remain anonymous. Read moreAuto Trait Implementations§
impl RefUnwindSafe for MessageEvent
impl !Send for MessageEvent
impl !Sync for MessageEvent
impl Unpin for MessageEvent
impl UnwindSafe for MessageEvent
Blanket Implementations§
source§impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
§type Abi = <T as IntoWasmAbi>::Abi
type Abi = <T as IntoWasmAbi>::Abi
IntoWasmAbi::Abi
source§fn return_abi(self, extra: &mut dyn Stack) -> <T as ReturnWasmAbi>::Abi
fn return_abi(self, extra: &mut dyn Stack) -> <T as ReturnWasmAbi>::Abi
IntoWasmAbi::into_abi
, except that it may throw and never
return in the case of Err
. Read more