pub enum DocumentLoadState {
Commit,
DomContentLoaded,
Load,
NetworkIdle,
}Expand description
Document load states for navigation waiting.
These states are compatible with Playwright’s load states and occur
in the following order: Commit → DomContentLoaded → Load → NetworkIdle
Variants§
Commit
Navigation response received (first byte). This is the earliest state and completes when the server starts sending a response.
DomContentLoaded
DOM fully parsed (DOMContentLoaded event fired).
The HTML document has been completely loaded and parsed.
Load
Full page load complete (load event fired). All resources including images, stylesheets, and scripts have loaded. This is the default wait state.
NetworkIdle
No network requests for 500ms. Useful for pages with dynamic content that loads after the initial page load.
Implementations§
Source§impl DocumentLoadState
impl DocumentLoadState
Sourcepub fn is_reached(&self, current: Self) -> bool
pub fn is_reached(&self, current: Self) -> bool
Check if this state has been reached given the current state.
Returns true if current is at or past self in the load order.
Sourcepub fn cdp_event_name(&self) -> Option<&'static str>
pub fn cdp_event_name(&self) -> Option<&'static str>
Get the CDP event name associated with this state.
Trait Implementations§
Source§impl Clone for DocumentLoadState
impl Clone for DocumentLoadState
Source§fn clone(&self) -> DocumentLoadState
fn clone(&self) -> DocumentLoadState
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for DocumentLoadState
impl Debug for DocumentLoadState
Source§impl Default for DocumentLoadState
impl Default for DocumentLoadState
Source§fn default() -> DocumentLoadState
fn default() -> DocumentLoadState
Source§impl Hash for DocumentLoadState
impl Hash for DocumentLoadState
Source§impl Ord for DocumentLoadState
impl Ord for DocumentLoadState
Source§fn cmp(&self, other: &DocumentLoadState) -> Ordering
fn cmp(&self, other: &DocumentLoadState) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for DocumentLoadState
impl PartialEq for DocumentLoadState
Source§impl PartialOrd for DocumentLoadState
impl PartialOrd for DocumentLoadState
impl Copy for DocumentLoadState
impl Eq for DocumentLoadState
impl StructuralPartialEq for DocumentLoadState
Auto Trait Implementations§
impl Freeze for DocumentLoadState
impl RefUnwindSafe for DocumentLoadState
impl Send for DocumentLoadState
impl Sync for DocumentLoadState
impl Unpin for DocumentLoadState
impl UnwindSafe for DocumentLoadState
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.