pub struct Handle<S> { /* private fields */ }
Expand description
The handle used for pulling or cloning changes from a remote peer.
Implementations§
Source§impl<S> Handle<S>
impl<S> Handle<S>
pub fn new(
local: PublicKey,
repo: Repository,
follow: Allowed,
blocked: BlockList,
connection: S,
) -> Result<Self, Init>where
S: ConnectionStream,
pub fn is_blocked(&self, key: &PublicKey) -> bool
pub fn repository(&self) -> &Repository
pub fn repository_mut(&mut self) -> &mut Repository
pub fn local(&self) -> &PublicKey
pub fn interrupt_pack_writer(&mut self)
pub fn verified(&self, head: Oid) -> Result<Doc, DocError>
pub fn allowed(&self) -> Allowed
Auto Trait Implementations§
impl<S> Freeze for Handle<S>where
S: Freeze,
impl<S> RefUnwindSafe for Handle<S>where
S: RefUnwindSafe,
impl<S> Send for Handle<S>where
S: Send,
impl<S> !Sync for Handle<S>
impl<S> Unpin for Handle<S>where
S: Unpin,
impl<S> UnwindSafe for Handle<S>where
S: UnwindSafe,
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> 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 more