org.eclipse.jgit.storage.dht
Class DhtRepository
java.lang.Object
org.eclipse.jgit.lib.Repository
org.eclipse.jgit.storage.dht.DhtRepository
public class DhtRepository
- extends Repository
A Git repository storing its objects and references in a DHT.
With the exception of repository creation, this class is thread-safe, but
readers created from it are not. When creating a new repository using the
create(boolean)
method, the newly constructed repository object does
not ensure the assigned getRepositoryKey()
will be visible to all
threads. Applications are encouraged to use their own synchronization when
sharing a Repository instance that was used to create a new repository.
Methods inherited from class org.eclipse.jgit.lib.Repository |
close, create, doClose, fireEvent, getAdditionalHaves, getAllRefs, getAllRefsByPeeledObjectId, getBranch, getDirectory, getFS, getFullBranch, getGlobalListenerList, getIndex, getIndexFile, getListenerList, getRef, getRepositoryState, getTags, getWorkTree, hasObject, incrementOpen, isBare, isValidRefName, lockDirCache, newObjectInserter, newObjectReader, open, open, peel, readCherryPickHead, readDirCache, readMergeCommitMsg, readMergeHeads, renameRef, resolve, shortenRefName, stripWorkDir, updateRef, updateRef, writeCherryPickHead, writeMergeCommitMsg, writeMergeHeads |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
DhtRepository
public DhtRepository(DhtRepositoryBuilder builder)
- Initialize an in-memory representation of a DHT backed repository.
- Parameters:
builder
- description of the repository and its data storage.
getDatabase
public Database getDatabase()
- Returns:
- database cluster that houses this repository (among others).
getRepositoryName
public RepositoryName getRepositoryName()
- Returns:
- human readable name used to open this repository.
getRepositoryKey
public RepositoryKey getRepositoryKey()
- Returns:
- unique identity of the repository in the
getDatabase()
.
getConfig
public StoredConfig getConfig()
- Specified by:
getConfig
in class Repository
getRefDatabase
public DhtRefDatabase getRefDatabase()
- Specified by:
getRefDatabase
in class Repository
getObjectDatabase
public DhtObjDatabase getObjectDatabase()
- Specified by:
getObjectDatabase
in class Repository
create
public void create(boolean bare)
throws java.io.IOException
- Specified by:
create
in class Repository
- Throws:
java.io.IOException
scanForRepoChanges
public void scanForRepoChanges()
- Specified by:
scanForRepoChanges
in class Repository
toString
public java.lang.String toString()
- Overrides:
toString
in class Repository
getReflogReader
public ReflogReader getReflogReader(java.lang.String refName)
- Specified by:
getReflogReader
in class Repository
Copyright © 2011. All Rights Reserved.