Skip to main content

SharedTransport

Type Alias SharedTransport 

Source
pub type SharedTransport = Arc<dyn Transport + Send + Sync>;
Expand description

A transport shared across the opener objects (BzrDir, Branch, Repository, WorkingTree).

They own their transport via this Arc rather than borrowing it, so a BzrDir can hand out sub-objects that outlive it, and the 2a repository’s CHK store (which needs Arc<S> with S: Send + Sync) is satisfiable. Send + Sync is required because the groupcompress stores implement the Send + Sync VersionedFiles trait.

Aliased Type§

pub struct SharedTransport { /* private fields */ }