summaryrefslogtreecommitdiff
path: root/include/git2/remote.h
diff options
context:
space:
mode:
authorPhilip Kelley <phkelley@hotmail.com>2014-06-25 13:20:27 -0400
committerPhilip Kelley <phkelley@hotmail.com>2014-06-26 22:34:37 -0400
commit1697cd6ff5d29c95106ff4b7bd56ebba5d51b8c1 (patch)
tree05e0f995c3782e0dd9b220b0fcc8ad09fc8dd96f /include/git2/remote.h
parent86cb34cb110c6a1ec6e1d1525418c70f2f617d6b (diff)
downloadlibgit2-1697cd6ff5d29c95106ff4b7bd56ebba5d51b8c1.tar.gz
Improvements to git_transport extensibility
git_remote_set_transport now takes a transport factory rather than a transport git_clone_options now allows the caller to specify a remote creation callback
Diffstat (limited to 'include/git2/remote.h')
-rw-r--r--include/git2/remote.h15
1 files changed, 7 insertions, 8 deletions
diff --git a/include/git2/remote.h b/include/git2/remote.h
index c72c9c8cc..c8b6ac97a 100644
--- a/include/git2/remote.h
+++ b/include/git2/remote.h
@@ -419,20 +419,19 @@ GIT_EXTERN(int) git_remote_list(git_strarray *out, git_repository *repo);
GIT_EXTERN(void) git_remote_check_cert(git_remote *remote, int check);
/**
- * Sets a custom transport for the remote. The caller can use this function
- * to bypass the automatic discovery of a transport by URL scheme (i.e.
- * http://, https://, git://) and supply their own transport to be used
- * instead. After providing the transport to a remote using this function,
- * the transport object belongs exclusively to that remote, and the remote will
- * free it when it is freed with git_remote_free.
+ * Sets a custom transport factory for the remote. The caller can use this
+ * function to override the transport used for this remote when performing
+ * network operations.
*
* @param remote the remote to configure
- * @param transport the transport object for the remote to use
+ * @param transport_cb the function to use to create a transport
+ * @param payload opaque parameter passed to transport_cb
* @return 0 or an error code
*/
GIT_EXTERN(int) git_remote_set_transport(
git_remote *remote,
- git_transport *transport);
+ git_transport_cb transport_cb,
+ void *payload);
/**
* Argument to the completion callback which tells it which operation