Function git_protocol::fetch [−][src]
pub fn fetch<F>(
transport: impl Transport,
delegate: &mut impl Delegate,
authenticate: F,
progress: impl Progress
) -> Result<(), Error> where
F: FnMut(Action<'_>) -> Result,
Perform a ‘fetch’ operation with the server using transport
, with delegate
handling all server interactions.
authenticate(operation_to_perform)
is used to receive credentials for the connection and potentially store it if the server indicates ‘permission denied’. Note that not all transport support authentication or authorization.progress
is used to emit progress messages.
Note that depending on the delegate
, the actual action performed can be ls-refs
, clone
or fetch
.