Trait script::dom::bindings::codegen::Bindings::EventSourceBinding::EventSource_Binding::EventSourceMethods
source · pub trait EventSourceMethods<D: DomTypes> {
// Required methods
fn Url(&self) -> DOMString;
fn WithCredentials(&self) -> bool;
fn ReadyState(&self) -> u16;
fn GetOnopen(&self) -> Option<Rc<EventHandlerNonNull>>;
fn SetOnopen(&self, value: Option<Rc<EventHandlerNonNull>>);
fn GetOnmessage(&self) -> Option<Rc<EventHandlerNonNull>>;
fn SetOnmessage(&self, value: Option<Rc<EventHandlerNonNull>>);
fn GetOnerror(&self) -> Option<Rc<EventHandlerNonNull>>;
fn SetOnerror(&self, value: Option<Rc<EventHandlerNonNull>>);
fn Close(&self);
fn Constructor(
global: &GlobalScope,
proto: Option<HandleObject<'_>>,
can_gc: CanGc,
url: DOMString,
eventSourceInitDict: &EventSourceInit,
) -> Result<Root<Dom<EventSource>>, Error>;
}
Required Methods§
fn Url(&self) -> DOMString
fn WithCredentials(&self) -> bool
fn ReadyState(&self) -> u16
fn GetOnopen(&self) -> Option<Rc<EventHandlerNonNull>>
fn SetOnopen(&self, value: Option<Rc<EventHandlerNonNull>>)
fn GetOnmessage(&self) -> Option<Rc<EventHandlerNonNull>>
fn SetOnmessage(&self, value: Option<Rc<EventHandlerNonNull>>)
fn GetOnerror(&self) -> Option<Rc<EventHandlerNonNull>>
fn SetOnerror(&self, value: Option<Rc<EventHandlerNonNull>>)
fn Close(&self)
fn Constructor( global: &GlobalScope, proto: Option<HandleObject<'_>>, can_gc: CanGc, url: DOMString, eventSourceInitDict: &EventSourceInit, ) -> Result<Root<Dom<EventSource>>, Error>
Object Safety§
This trait is not object safe.