pub struct ContextRequest { /* private fields */ }Expand description
Repo refetch request prepared by the viewer for asynchronous context updates.
Implementations§
Source§impl ContextRequest
impl ContextRequest
Sourcepub const fn context_lines(&self) -> usize
pub const fn context_lines(&self) -> usize
Returns the Git context width to fetch.
Sourcepub fn paths(&self) -> impl Iterator<Item = &Path>
pub fn paths(&self) -> impl Iterator<Item = &Path>
Returns the paths that should be fetched from the repo.
Sourcepub fn decode(self, patch: &[u8]) -> Result<Option<ContextUpdate>, DecodeError>
pub fn decode(self, patch: &[u8]) -> Result<Option<ContextUpdate>, DecodeError>
Decodes a repo patch into a viewer update.
Trait Implementations§
Source§impl Clone for ContextRequest
impl Clone for ContextRequest
Source§fn clone(&self) -> ContextRequest
fn clone(&self) -> ContextRequest
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§
impl Freeze for ContextRequest
impl RefUnwindSafe for ContextRequest
impl Send for ContextRequest
impl Sync for ContextRequest
impl Unpin for ContextRequest
impl UnsafeUnpin for ContextRequest
impl UnwindSafe for ContextRequest
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