pub enum SessionHistoryDiff {
BrowsingContext {
browsing_context_id: BrowsingContextId,
old_reloader: NeedsToReload,
new_reloader: NeedsToReload,
},
Pipeline {
pipeline_reloader: NeedsToReload,
old_history_state_id: Option<HistoryStateId>,
old_url: ServoUrl,
new_history_state_id: HistoryStateId,
new_url: ServoUrl,
},
Hash {
pipeline_reloader: NeedsToReload,
old_url: ServoUrl,
new_url: ServoUrl,
},
}
Expand description
Represents a the difference between two adjacent session history entries.
Variants§
BrowsingContext
Represents a diff where the active pipeline of an entry changed.
Fields
§
browsing_context_id: BrowsingContextId
The browsing context whose pipeline changed
§
old_reloader: NeedsToReload
The previous pipeline (used when traversing into the past)
§
new_reloader: NeedsToReload
The next pipeline (used when traversing into the future)
Pipeline
Represents a diff where the active state of a pipeline changed.
Fields
§
pipeline_reloader: NeedsToReload
The pipeline whose history state changed.
§
old_history_state_id: Option<HistoryStateId>
The old history state id.
§
new_history_state_id: HistoryStateId
The new history state id.
Hash
Implementations§
source§impl SessionHistoryDiff
impl SessionHistoryDiff
sourcepub fn alive_old_pipeline(&self) -> Option<PipelineId>
pub fn alive_old_pipeline(&self) -> Option<PipelineId>
Returns the old pipeline id if that pipeline is still alive, otherwise returns None
sourcepub fn alive_new_pipeline(&self) -> Option<PipelineId>
pub fn alive_new_pipeline(&self) -> Option<PipelineId>
Returns the new pipeline id if that pipeline is still alive, otherwise returns None
sourcepub fn replace_reloader(
&mut self,
replaced_reloader: &NeedsToReload,
reloader: &NeedsToReload,
)
pub fn replace_reloader( &mut self, replaced_reloader: &NeedsToReload, reloader: &NeedsToReload, )
Replaces all occurances of the replaced pipeline with a new pipeline
Trait Implementations§
Auto Trait Implementations§
impl Freeze for SessionHistoryDiff
impl RefUnwindSafe for SessionHistoryDiff
impl Send for SessionHistoryDiff
impl Sync for SessionHistoryDiff
impl Unpin for SessionHistoryDiff
impl UnwindSafe for SessionHistoryDiff
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
Mutably borrows from an owned value. Read more
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§impl<T> MaybeBoxed<Box<T>> for T
impl<T> MaybeBoxed<Box<T>> for T
source§fn maybe_boxed(self) -> Box<T>
fn maybe_boxed(self) -> Box<T>
Convert
source§impl<T> MaybeBoxed<T> for T
impl<T> MaybeBoxed<T> for T
source§fn maybe_boxed(self) -> T
fn maybe_boxed(self) -> T
Convert