Method | Description | |
---|---|---|
Close ( ) : void |
Close all resources used by this repository
|
|
Create ( ) : void |
Create a new Git repository initializing the necessary files and directories.
|
|
Create ( bool bare ) : void |
Create a new Git repository initializing the necessary files and directories.
|
|
Dispose ( ) : void | ||
HasObject ( AnyObjectId objectId ) : bool |
|
|
IncrementOpen ( ) : void | ||
IsValidRefName ( string refName ) : bool |
Check validity of a ref name. It must not contain character that has a special meaning in a Git object reference expression. Some other dangerous characters are also excluded.
|
|
Link ( string name, string target ) : void | ||
MapCommit ( ObjectId id ) : Commit |
Access a Commit by SHA'1 id.
|
|
MapCommit ( string resolveString ) : Commit |
Access a Commit object using a symbolic reference. This reference may be a SHA-1 or ref in combination with a number of symbols translating from one ref or SHA1-1 to another, such as HEAD^ etc.
|
|
MapObject ( ObjectId id, string refName ) : object |
Access any type of Git object by id and
|
|
MapTag ( string revstr ) : Tag |
Access a tag by symbolic name.
|
|
MapTag ( string refName, ObjectId id ) : Tag |
Access a Tag by SHA'1 id
|
|
MapTree ( ObjectId id ) : Tree |
Access a Tree by SHA'1 id.
|
|
MapTree ( string revstr ) : Tree |
Access a Tree object using a symbolic reference. This reference may be a SHA-1 or ref in combination with a number of symbols translating from one ref or SHA1-1 to another, such as HEAD^{tree} etc.
|
|
Open ( DirectoryInfo directory ) : Repository | ||
Open ( string directory ) : Repository | ||
OpenBlob ( ObjectId id ) : ObjectLoader |
|
|
OpenCommit ( ObjectId id ) : Commit | ||
OpenObject ( AnyObjectId id ) : ObjectLoader |
|
|
OpenObject ( WindowCursor windowCursor, AnyObjectId id ) : ObjectLoader |
|
|
OpenObjectInAllPacks ( AnyObjectId objectId, WindowCursor windowCursor ) : IEnumerable |
Open object in all packs containing specified object.
|
|
OpenObjectInAllPacks ( AnyObjectId objectId, ICollection |
Open object in all packs containing specified object.
|
|
OpenPack ( FileInfo pack, FileInfo idx ) : void | ||
OpenTree ( ObjectId id ) : ObjectLoader |
|
|
Peel ( Ref pRef ) : Ref | ||
ReflogReader ( string refName ) : ReflogReader |
|
|
RefreshFromDisk ( ) : void |
Clean up stale caches.
|
|
RenameRef ( string fromRef, string toRef ) : RefRename |
Create a command to rename a ref in this repository
|
|
Repository ( DirectoryInfo d ) : System |
Construct a representation of a Git repository. The work tree, object directory, alternate object directories and index file locations are deduced from the given git directory and the default rules.
|
|
Repository ( DirectoryInfo d, DirectoryInfo workTree ) : System |
Construct a representation of a Git repository. The work tree, object directory, alternate object directories and index file locations are deduced from the given git directory and the default rules.
|
|
Repository ( DirectoryInfo d, DirectoryInfo workTree, DirectoryInfo objectDir, DirectoryInfo alternateObjectDir, FileInfo indexFile ) : System |
Construct a representation of a Git repository using the given parameters possibly overriding default conventions..
|
|
Resolve ( string revision ) : ObjectId |
Parse a git revision string and return an object id.
|
|
ShortenRefName ( string refName ) : string |
|
|
StripWorkDir ( FileSystemInfo workDir, FileSystemInfo file ) : string |
Strip work dir and return normalized repository path
|
|
ToFile ( AnyObjectId objectId ) : FileInfo |
Construct a filename where the loose object having a specified SHA-1 should be stored. If the object is stored in a shared repository the path to the alternative repo will be returned. If the object is not yet store a usable path in this repo will be returned. It is assumed that callers will look for objects in a pack first.
|
|
ToString ( ) : string | ||
UpdateRef ( string refName ) : RefUpdate |
Create a command to update (or create) a ref in this repository.
|
|
UpdateRef ( string refName, bool detach ) : RefUpdate |
Create a command to update, create or delete a ref in this repository.
|
|
WriteSymref ( string name, string target ) : void |
Writes a symref (e.g. HEAD) to disk
|
|
addAnyRepositoryChangedListener ( RepositoryListener l ) : void | ||
addRepositoryChangedListener ( RepositoryListener l ) : void | ||
getAllRefs ( ) : Ref>.Dictionary |
||
getAllRefsByPeeledObjectId ( ) : List>.Dictionary |
||
getBranch ( ) : string | ||
getIndexFile ( ) : FileInfo | ||
getRef ( string name ) : Ref | ||
getTags ( ) : Ref>.Dictionary |
||
removeAnyRepositoryChangedListener ( RepositoryListener l ) : void | ||
removeRepositoryChangedListener ( RepositoryListener l ) : void | ||
scanForRepoChanges ( ) : void | ||
setWorkDir ( DirectoryInfo workTree ) : void |
Override default workdir
|
Method | Description | |
---|---|---|
GitInternalSlash ( byte bytes ) : byte[] |
Replaces any windows director separators (backslash) with /
|
|
MakeCommit ( ObjectId id, byte raw ) : object | ||
MakeTag ( ObjectId id, string refName, byte raw ) : Tag | ||
MakeTree ( ObjectId id, byte raw ) : Tree | ||
ResolveSimple ( string revstr ) : ObjectId | ||
fireIndexChanged ( ) : void | ||
fireRefsMaybeChanged ( ) : void |
public Create ( bool bare ) : void | ||
bare | bool | if true, a bare repository is created. |
return | void |
public HasObject ( AnyObjectId objectId ) : bool | ||
objectId | AnyObjectId | |
return | bool |
public static IsValidRefName ( string refName ) : bool | ||
refName | string | |
return | bool |
public Link ( string name, string target ) : void | ||
name | string | |
target | string | |
return | void |
public MapCommit ( string resolveString ) : Commit | ||
resolveString | string | a reference to a git commit object |
return | Commit |
public MapObject ( ObjectId id, string refName ) : object | ||
id | ObjectId | SHA-1 of object to read |
refName | string | optional, only relevant for simple tags |
return | object |
public MapTag ( string refName, ObjectId id ) : Tag | ||
refName | string | |
id | ObjectId | |
return | Tag |
public MapTree ( string revstr ) : Tree | ||
revstr | string | a reference to a git commit object |
return | Tree |
public static Open ( DirectoryInfo directory ) : Repository | ||
directory | DirectoryInfo | |
return | Repository |
public static Open ( string directory ) : Repository | ||
directory | string | |
return | Repository |
public OpenBlob ( ObjectId id ) : ObjectLoader | ||
id | ObjectId | SHA'1 of a blob |
return | ObjectLoader |
public OpenObject ( AnyObjectId id ) : ObjectLoader | ||
id | AnyObjectId | SHA-1 of an object. |
return | ObjectLoader |
public OpenObject ( WindowCursor windowCursor, AnyObjectId id ) : ObjectLoader | ||
windowCursor | WindowCursor | /// Temporary working space associated with the calling thread. /// |
id | AnyObjectId | SHA-1 of an object. |
return | ObjectLoader |
public OpenObjectInAllPacks ( AnyObjectId objectId, WindowCursor windowCursor ) : IEnumerable |
||
objectId | AnyObjectId | id of object to search for |
windowCursor | WindowCursor | /// Temporary working space associated with the calling thread. /// |
return | IEnumerable |
public OpenObjectInAllPacks ( AnyObjectId objectId, ICollection |
||
objectId | AnyObjectId | |
resultLoaders | ICollection |
/// Result collection of loaders for this object, filled with /// loaders from all packs containing specified object /// |
windowCursor | WindowCursor | /// Temporary working space associated with the calling thread. /// |
return | void |
public OpenPack ( FileInfo pack, FileInfo idx ) : void | ||
pack | FileInfo | |
idx | FileInfo | |
return | void |
public OpenTree ( ObjectId id ) : ObjectLoader | ||
id | ObjectId | SHA'1 of a tree |
return | ObjectLoader |
public ReflogReader ( string refName ) : ReflogReader | ||
refName | string | |
return | ReflogReader |
public RenameRef ( string fromRef, string toRef ) : RefRename | ||
fromRef | string | Name of ref to rename from. |
toRef | string | Name of ref to rename to. |
return | RefRename |
public Repository ( DirectoryInfo d ) : System | ||
d | DirectoryInfo | GIT_DIR (the location of the repository metadata). |
return | System |
public Repository ( DirectoryInfo d, DirectoryInfo workTree ) : System | ||
d | DirectoryInfo | GIT_DIR (the location of the repository metadata). |
workTree | DirectoryInfo | GIT_WORK_TREE (the root of the checkout). May be null for default value. |
return | System |
public Repository ( DirectoryInfo d, DirectoryInfo workTree, DirectoryInfo objectDir, DirectoryInfo alternateObjectDir, FileInfo indexFile ) : System | ||
d | DirectoryInfo | GIT_DIR (the location of the repository metadata). May be null for default value in which case it depends on GIT_WORK_TREE. |
workTree | DirectoryInfo | GIT_WORK_TREE (the root of the checkout). May be null for default value if GIT_DIR is |
objectDir | DirectoryInfo | GIT_OBJECT_DIRECTORY (where objects and are stored). May be null for default value. Relative names ares resolved against GIT_WORK_TREE |
alternateObjectDir | DirectoryInfo | GIT_ALTERNATE_OBJECT_DIRECTORIES (where more objects are read from). May be null for default value. Relative names ares resolved against GIT_WORK_TREE |
indexFile | FileInfo | GIT_INDEX_FILE (the location of the index file). May be null for default value. Relative names ares resolved against GIT_WORK_TREE. |
return | System |
public Resolve ( string revision ) : ObjectId | ||
revision | string | A git object references expression. |
return | ObjectId |
public static ShortenRefName ( string refName ) : string | ||
refName | string | |
return | string |
public static StripWorkDir ( FileSystemInfo workDir, FileSystemInfo file ) : string | ||
workDir | FileSystemInfo | Work directory |
file | FileSystemInfo | File whose path shall be stripp off it's workdir |
return | string |
public ToFile ( AnyObjectId objectId ) : FileInfo | ||
objectId | AnyObjectId | |
return | FileInfo |
public UpdateRef ( string refName ) : RefUpdate | ||
refName | string | /// name of the ref the caller wants to modify. /// |
return | RefUpdate |
public UpdateRef ( string refName, bool detach ) : RefUpdate | ||
refName | string | name of the ref the caller wants to modify. |
detach | bool | true to create a detached head |
return | RefUpdate |
public WriteSymref ( string name, string target ) : void | ||
name | string | symref name |
target | string | pointed to ref |
return | void |
public static addAnyRepositoryChangedListener ( RepositoryListener l ) : void | ||
l | RepositoryListener | |
return | void |
public addRepositoryChangedListener ( RepositoryListener l ) : void | ||
l | RepositoryListener | |
return | void |
public getAllRefsByPeeledObjectId ( ) : List>.Dictionary |
||
return | List>.Dictionary |
public static removeAnyRepositoryChangedListener ( RepositoryListener l ) : void | ||
l | RepositoryListener | |
return | void |
public removeRepositoryChangedListener ( RepositoryListener l ) : void | ||
l | RepositoryListener | |
return | void |
public setWorkDir ( DirectoryInfo workTree ) : void | ||
workTree | DirectoryInfo | the work tree directory |
return | void |