diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-04 12:41:41 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-04 12:41:41 +0000 |
commit | 10ee2acdd26a7f1298c6f6d6b7af9b469fe29b87 (patch) | |
tree | bdffd5d80c26cf4a7a518281a204be1ace85b4c1 /vendor/gix/src/remote/connection/mod.rs | |
parent | Releasing progress-linux version 1.70.0+dfsg1-9~progress7.99u1. (diff) | |
download | rustc-10ee2acdd26a7f1298c6f6d6b7af9b469fe29b87.tar.xz rustc-10ee2acdd26a7f1298c6f6d6b7af9b469fe29b87.zip |
Merging upstream version 1.70.0+dfsg2.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'vendor/gix/src/remote/connection/mod.rs')
-rw-r--r-- | vendor/gix/src/remote/connection/mod.rs | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/vendor/gix/src/remote/connection/mod.rs b/vendor/gix/src/remote/connection/mod.rs new file mode 100644 index 000000000..09943ecc4 --- /dev/null +++ b/vendor/gix/src/remote/connection/mod.rs @@ -0,0 +1,29 @@ +use crate::Remote; + +pub(crate) struct HandshakeWithRefs { + outcome: gix_protocol::handshake::Outcome, + refs: Vec<gix_protocol::handshake::Ref>, +} + +/// A function that performs a given credential action, trying to obtain credentials for an operation that needs it. +pub type AuthenticateFn<'a> = Box<dyn FnMut(gix_credentials::helper::Action) -> gix_credentials::protocol::Result + 'a>; + +/// A type to represent an ongoing connection to a remote host, typically with the connection already established. +/// +/// It can be used to perform a variety of operations with the remote without worrying about protocol details, +/// much like a remote procedure call. +pub struct Connection<'a, 'repo, T, P> { + pub(crate) remote: &'a Remote<'repo>, + pub(crate) authenticate: Option<AuthenticateFn<'a>>, + pub(crate) transport_options: Option<Box<dyn std::any::Any>>, + pub(crate) transport: T, + pub(crate) progress: P, +} + +mod access; + +/// +pub mod ref_map; + +/// +pub mod fetch; |