pub struct RepoLinkV0 {
pub id: RepoId,
pub read_cap: ReadCap,
pub overlay: OverlayLink,
pub peers: Vec<PeerAdvert>,
}
Expand description
Link to a repository
Consists of an identifier (repoid), a ReadCap or WriteCap, and a locator (peers and overlayLink) Those capabilities are not durable: They can be refreshed by the members and previously shared Caps will become obsolete/revoked. As long as the user is a member of the repo and subscribes to the root topic (of the repo, and of the store if needed/applicable), they will receive the updated capabilities. But if they don’t subscribe, they will lose access after the refresh. For durable capabilities, see PermaCap. In most cases, the link is shared and then the recipient opens it and subscribes soon afterward, so there is no need for a PermaCap Perma capabilities are needed only when the link is stored on disk and kept there unopened for a long period.
Fields§
§id: RepoId
Repository ID
read_cap: ReadCap
read capability for the whole repo current (at the time of sharing the link) root branch definition commit
overlay: OverlayLink
Write capability secret. Only set for editors. in this case, overlay MUST be set to an InnerOverlay Current overlay link, used to join the overlay
peers: Vec<PeerAdvert>
Peer brokers to connect to
Trait Implementations§
Source§impl Clone for RepoLinkV0
impl Clone for RepoLinkV0
Source§fn clone(&self) -> RepoLinkV0
fn clone(&self) -> RepoLinkV0
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for RepoLinkV0
impl Debug for RepoLinkV0
Source§impl<'de> Deserialize<'de> for RepoLinkV0
impl<'de> Deserialize<'de> for RepoLinkV0
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl Freeze for RepoLinkV0
impl RefUnwindSafe for RepoLinkV0
impl Send for RepoLinkV0
impl Sync for RepoLinkV0
impl Unpin for RepoLinkV0
impl UnwindSafe for RepoLinkV0
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<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>
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>
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