diff options
author | Shawn O. Pearce <spearce@spearce.org> | 2011-02-14 09:02:57 -0800 |
---|---|---|
committer | Shawn O. Pearce <spearce@spearce.org> | 2011-02-15 16:32:51 -0800 |
commit | 1f7982f64236f88f499193224c49e0a244e5d76a (patch) | |
tree | 00d77554fd50f7a3eaae1dab0e7f647df333c39f | |
parent | a06be83045f8aa0584137849c412dd6b3de8d5fe (diff) | |
download | jgit-1f7982f64236f88f499193224c49e0a244e5d76a.tar.gz jgit-1f7982f64236f88f499193224c49e0a244e5d76a.zip |
UploadPack: Expose advertised refs to callers
Like ReceivePack, callers that embed UploadPack within their
service may wish to see the set of references that were sent
to the client. We already have the map on hand, it just needs
to be exposed with a getter.
Change-Id: I123b23e475860d5bb968906bef59068985088b7b
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
-rw-r--r-- | org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java index 19ef019b92..e50b01ecc0 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java @@ -218,6 +218,11 @@ public class UploadPack { return walk; } + /** @return all refs which were advertised to the client. */ + public final Map<String, Ref> getAdvertisedRefs() { + return refs; + } + /** @return timeout (in seconds) before aborting an IO operation. */ public int getTimeout() { return timeout; |