pub struct Effects<S> { /* private fields */ }Expand description
What an event left for the server and the browser to do.
Simulation::click and the other events return it. Each method reads
one kind of record, by the typed value the page built it from.
Implementations§
Source§impl<S> Effects<S>
impl<S> Effects<S>
Sourcepub fn calls<E: Endpoint<S>>(&self, endpoint: &E) -> Vec<E::Args>where
E::Args: DeserializeOwned,
pub fn calls<E: Endpoint<S>>(&self, endpoint: &E) -> Vec<E::Args>where
E::Args: DeserializeOwned,
The arguments of each call to endpoint the event sent, in order.
An Action that takes no arguments gives one () per call. The
arguments are the ones the call evaluated when the event ran it.
§Panics
Panics if the arguments do not deserialize into the endpoint’s
argument type, which happens where a Serialize impl disagrees with
its Deserialize impl.
The URL the first Link::navigate the event ran loads.
Sourcepub fn pushes_url(&self) -> Option<&Url>
pub fn pushes_url(&self) -> Option<&Url>
The URL the first Link::push_url the event ran shows.
Sourcepub fn replaces_url(&self) -> Option<&Url>
pub fn replaces_url(&self) -> Option<&Url>
The URL the first Link::replace_url the event ran shows.
Sourcepub fn runs_in_browser(&self, stmt: impl IntoStmt<S>) -> bool
pub fn runs_in_browser(&self, stmt: impl IntoStmt<S>) -> bool
Whether the event asked the browser to run stmt, such as FIELD.focus().
It covers the statements of a NodeRef and a DialogRef and
FileInput::clear. For a.then(b), it says whether the event
asked for both. Any other statement gives false, because the
simulation runs it itself.