class FetchProcess
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private java.util.HashMap<ObjectId,Ref> |
askFor
Set of refs we will actually wind up asking to obtain.
|
private FetchConnection |
conn |
private java.util.ArrayList<FetchHeadRecord> |
fetchHeadUpdates
Records to be recorded into FETCH_HEAD.
|
private java.util.HashSet<ObjectId> |
have
Objects we know we have locally.
|
private java.util.Map<java.lang.String,Ref> |
localRefs |
private java.util.ArrayList<TrackingRefUpdate> |
localUpdates
Updates to local tracking branches (if any).
|
private java.util.ArrayList<PackLock> |
packLocks |
private java.util.Collection<RefSpec> |
toFetch
List of things we want to fetch from the remote repository.
|
private Transport |
transport
Transport we will fetch over.
|
Constructor and Description |
---|
FetchProcess(Transport t,
java.util.Collection<RefSpec> f) |
Modifier and Type | Method and Description |
---|---|
private void |
addUpdateBatchCommands(FetchResult result,
BatchRefUpdate batch) |
private boolean |
askForIsComplete() |
private void |
closeConnection(FetchResult result) |
private TrackingRefUpdate |
createUpdate(RefSpec spec,
ObjectId newId) |
private void |
deleteStaleTrackingRefs(FetchResult result,
BatchRefUpdate batch) |
private void |
deleteTrackingRef(FetchResult result,
BatchRefUpdate batch,
RefSpec spec,
Ref localRef) |
(package private) void |
execute(ProgressMonitor monitor,
FetchResult result) |
private void |
executeImp(ProgressMonitor monitor,
FetchResult result) |
private java.util.Collection<Ref> |
expandAutoFollowTags() |
private void |
expandFetchTags() |
private void |
expandSingle(RefSpec spec,
java.util.Set<Ref> matched) |
private void |
expandWildcard(RefSpec spec,
java.util.Set<Ref> matched) |
private void |
fetchObjects(ProgressMonitor monitor) |
private static java.lang.String |
getFirstFailedRefName(BatchRefUpdate batch) |
private static boolean |
isTag(Ref r) |
private static boolean |
isTag(java.lang.String name) |
private boolean |
localHasObject(ObjectId id) |
private java.util.Map<java.lang.String,Ref> |
localRefs() |
private void |
removeFetchHeadRecord(ObjectId want) |
private void |
removeTrackingRefUpdate(ObjectId want) |
private void |
reopenConnection() |
private void |
updateFETCH_HEAD(FetchResult result) |
private void |
want(ObjectId id) |
private void |
want(Ref src,
RefSpec spec) |
private void |
wantTag(Ref r) |
private final Transport transport
private final java.util.Collection<RefSpec> toFetch
private final java.util.HashMap<ObjectId,Ref> askFor
private final java.util.HashSet<ObjectId> have
private final java.util.ArrayList<TrackingRefUpdate> localUpdates
private final java.util.ArrayList<FetchHeadRecord> fetchHeadUpdates
private final java.util.ArrayList<PackLock> packLocks
private FetchConnection conn
private java.util.Map<java.lang.String,Ref> localRefs
void execute(ProgressMonitor monitor, FetchResult result) throws NotSupportedException, TransportException
private void executeImp(ProgressMonitor monitor, FetchResult result) throws NotSupportedException, TransportException
private void addUpdateBatchCommands(FetchResult result, BatchRefUpdate batch) throws TransportException
TransportException
private void fetchObjects(ProgressMonitor monitor) throws TransportException
TransportException
private void closeConnection(FetchResult result)
private void reopenConnection() throws NotSupportedException, TransportException
private void removeTrackingRefUpdate(ObjectId want)
private void removeFetchHeadRecord(ObjectId want)
private void updateFETCH_HEAD(FetchResult result) throws java.io.IOException
java.io.IOException
private boolean askForIsComplete() throws TransportException
TransportException
private void expandWildcard(RefSpec spec, java.util.Set<Ref> matched) throws TransportException
TransportException
private void expandSingle(RefSpec spec, java.util.Set<Ref> matched) throws TransportException
TransportException
private boolean localHasObject(ObjectId id) throws TransportException
TransportException
private java.util.Collection<Ref> expandAutoFollowTags() throws TransportException
TransportException
private void expandFetchTags() throws TransportException
TransportException
private void wantTag(Ref r) throws TransportException
TransportException
private void want(Ref src, RefSpec spec) throws TransportException
TransportException
private void want(ObjectId id)
private TrackingRefUpdate createUpdate(RefSpec spec, ObjectId newId) throws TransportException
TransportException
private java.util.Map<java.lang.String,Ref> localRefs() throws TransportException
TransportException
private void deleteStaleTrackingRefs(FetchResult result, BatchRefUpdate batch) throws java.io.IOException
java.io.IOException
private void deleteTrackingRef(FetchResult result, BatchRefUpdate batch, RefSpec spec, Ref localRef)
private static boolean isTag(Ref r)
private static boolean isTag(java.lang.String name)
private static java.lang.String getFirstFailedRefName(BatchRefUpdate batch)