pub struct NavBackStack<K: NavKey> { /* private fields */ }Implementations§
pub fn top(&self) -> Option<(u64, K, Rc<SavedState>, Scope)>
pub fn size(&self) -> usize
pub fn last_dir(&self) -> TransitionDir
pub fn to_json(&self) -> Stringwhere
K: Serialize,
Sourcepub fn from_json(&self, json: &str)where
K: for<'de> Deserialize<'de>,
pub fn from_json(&self, json: &str)where
K: for<'de> Deserialize<'de>,
Restore from to_json output. Rejects empty/malformed payloads and
always keeps at least one entry, so a failed restore can never leave
the navigator rendering an empty screen with a dead back handler.
Trait Implementations§
Source§fn clone(&self) -> NavBackStack<K>
fn clone(&self) -> NavBackStack<K>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
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