Java org.eclipse.jgit.lib Repository fields, constructors, methods, implement or subclass

Example usage for Java org.eclipse.jgit.lib Repository fields, constructors, methods, implement or subclass

Introduction

In this page you can find the methods, fields and constructors for org.eclipse.jgit.lib Repository.

The text is from its open source code.

Subclass

org.eclipse.jgit.lib.Repository has subclasses.
Click this link to see all its subclasses.

Constructor

Repository(BaseRepositoryBuilder options)
Initialize a new repository instance.

Method

voidclose()

Decrement the use count, and maybe close resources.

voidcreate()
Create a new Git repository.
voidcreate(boolean bare)
Create a new Git repository initializing the necessary files and directories.
AttributesNodeProvidercreateAttributesNodeProvider()
Create a new org.eclipse.jgit.attributes.AttributesNodeProvider .
RefexactRef(String name)
Get a ref by name.
ReffindRef(String name)
Search for a ref by (possibly abbreviated) name.
voidfireEvent(RepositoryEvent event)
Fire an event to all registered listeners.
MapgetAllRefs()
Get mutable map of all known refs, including symrefs like HEAD that may not point to any object yet.
Map>getAllRefsByPeeledObjectId()
Get a map with all objects referenced by a peeled ref.
StringgetBranch()
Get the short name of the current branch that HEAD points to.
StoredConfiggetConfig()
Get the configuration of this repository.
FilegetDirectory()
Get local metadata directory
FSgetFS()
Get the used file system abstraction.
StringgetFullBranch()
Get the name of the reference that HEAD points to.
ListenerListgetGlobalListenerList()
Get the global listener list observing all events in this JVM.
FilegetIndexFile()
Get the index file location or null if repository isn't local.
ListenerListgetListenerList()
Get listeners observing only events on this repository.
ObjectDatabasegetObjectDatabase()
Get the object database which stores this repository's data.
RefDatabasegetRefDatabase()
Get the reference database which stores the reference namespace.
StringgetRemoteName(String refName)
Get remote name
SetgetRemoteNames()
Get the names of all known remotes
RepositoryStategetRepositoryState()
Get the repository state
MapgetTags()
Get mutable map of all tags
FilegetWorkTree()
Get the root directory of the working tree, where files are checked out for viewing and editing.
booleanhasObject(AnyObjectId objectId)
Whether the specified object is stored in this repo or any of the known shared repositories.
booleanisBare()
Whether this repository is bare
booleanisValidRefName(String refName)
Check validity of a ref name.
DirCachelockDirCache()
Create a new in-core index representation, lock it, and read from disk.
ObjectInserternewObjectInserter()
Create a new inserter to create objects in #getObjectDatabase() .
ObjectReadernewObjectReader()
Create a new reader to read objects from #getObjectDatabase() .
StringnormalizeBranchName(String name)
Normalizes the passed branch name into a possible valid branch name.
ObjectLoaderopen(AnyObjectId objectId)
Open an object from this repository.
ObjectLoaderopen(AnyObjectId objectId, int typeHint)
Open an object from this repository.
Refpeel(Ref ref)
Peel a possibly unpeeled reference to an annotated tag.
ObjectIdreadCherryPickHead()
Return the information stored in the file $GIT_DIR/CHERRY_PICK_HEAD.
DirCachereadDirCache()
Create a new in-core index representation and read an index from disk.
ListreadRebaseTodo(String path, boolean includeComments)
Read a file formatted like the git-rebase-todo file.
StringreadSquashCommitMsg()
Return the information stored in the file $GIT_DIR/SQUASH_MSG.
RefRenamerenameRef(String fromRef, String toRef)
Create a command to rename a ref in this repository
ObjectIdresolve(String revstr)
Parse a git revision string and return an object id.
StringshortenRefName(String refName)
Get a shortened more user friendly ref name
StringstripWorkDir(File workDir, File file)
Strip work dir and return normalized repository path.
StringtoString()
RefUpdateupdateRef(String ref)
Create a command to update, create or delete a ref in this repository.
RefUpdateupdateRef(String ref, boolean detach)
Create a command to update, create or delete a ref in this repository.
voidwriteCherryPickHead(ObjectId head)
Write cherry pick commit into $GIT_DIR/CHERRY_PICK_HEAD.
voidwriteMergeCommitMsg(String msg)
Write new content to the file $GIT_DIR/MERGE_MSG.
voidwriteMergeHeads(List heads)
Write new merge-heads into $GIT_DIR/MERGE_HEAD.
voidwriteRebaseTodoFile(String path, List steps, boolean append)
Write a file formatted like a git-rebase-todo file.
voidwriteRevertHead(ObjectId head)
Write revert commit into $GIT_DIR/REVERT_HEAD.
voidwriteSquashCommitMsg(String msg)
Write new content to the file $GIT_DIR/SQUASH_MSG.