C# 클래스 GitSharp.Core.ObjectDatabase

Abstraction of arbitrary object storage. An object database stores one or more Git objects, indexed by their unique ObjectId. Optionally an object database can reference one or more alternates; other ObjectDatabase instances that are searched in addition to the current database. Databases are usually divided into two halves: a half that is considered to be fast to search, and a half that is considered to be slow to search. When alternates are present the fast half is fully searched (recursively through all alternates) before the slow half is considered.
상속: IDisposable
파일 보기 프로젝트 열기: jagregory/GitSharp 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
NoAlternates GitSharp.Core.ObjectDatabase[]

공개 메소드들

메소드 설명
Dispose ( ) : void
OpenObjectInAllPacks ( ICollection @out, GitSharp.Core.WindowCursor windowCursor, AnyObjectId objectId ) : void

Open the object from all packs containing it. If any alternates are present, their packs are also considered.

OpenObjectInAllPacksImplementation ( ICollection @out, GitSharp.Core.WindowCursor windowCursor, AnyObjectId objectId ) : void

Open the object from all packs containing it. If any alternates are present, their packs are also considered.

close ( ) : void

Close any resources held by this database and its active alternates.

closeAlternates ( ) : void

Fully close all loaded alternates and clear the alternate list.

closeSelf ( ) : void

Close any resources held by this database only; ignoring alternates. To fully close this database and its referenced alternates, the caller should instead invoke close().

create ( ) : void

Initialize a new object database at this location.

exists ( ) : bool

Gets if this database is already created; If it returns false, the caller should invoke create to create this database location.

getAlternates ( ) : GitSharp.Core.ObjectDatabase[]

Get the alternate databases known to this database.

hasObject ( AnyObjectId objectId ) : bool

Does the requested object exist in this database? Alternates (if present) are searched automatically.

hasObject1 ( AnyObjectId objectId ) : bool

Fast half of hasObject(AnyObjectId).

hasObject2 ( string objectName ) : bool

Slow half of hasObject(AnyObjectId).

loadAlternates ( ) : GitSharp.Core.ObjectDatabase[]

Load the list of alternate databases into memory. This method is invoked by getAlternates() if the alternate list has not yet been populated, or if closeAlternates() has been called on this instance and the alternate list is needed again. If the alternate array is empty, implementors should consider using the constant NoAlternates.

openObject ( GitSharp.Core.WindowCursor curs, AnyObjectId objectId ) : GitSharp.Core.ObjectLoader

Open an object from this database. Alternates (if present) are searched automatically.

openObject1 ( GitSharp.Core.WindowCursor curs, AnyObjectId objectId ) : GitSharp.Core.ObjectLoader

Fast half of openObject(WindowCursor, AnyObjectId).

openObject2 ( GitSharp.Core.WindowCursor curs, string objectName, AnyObjectId objectId ) : GitSharp.Core.ObjectLoader

Slow half of openObject(WindowCursor, AnyObjectId).

tryAgain1 ( ) : bool

true if the fast-half search should be tried again.

보호된 메소드들

메소드 설명
ObjectDatabase ( ) : System

Initialize a new database instance for access.

closeAlternates ( ObjectDatabase alt ) : void

비공개 메소드들

메소드 설명
OpenObjectImpl1 ( GitSharp.Core.WindowCursor curs, AnyObjectId objectId ) : GitSharp.Core.ObjectLoader
OpenObjectImpl2 ( GitSharp.Core.WindowCursor curs, string objectName, AnyObjectId objectId ) : GitSharp.Core.ObjectLoader
hasObjectImpl1 ( AnyObjectId objectId ) : bool
hasObjectImpl2 ( string objectId ) : bool

메소드 상세

Dispose() 공개 메소드

public Dispose ( ) : void
리턴 void

ObjectDatabase() 보호된 메소드

Initialize a new database instance for access.
protected ObjectDatabase ( ) : System
리턴 System

OpenObjectInAllPacks() 공개 메소드

Open the object from all packs containing it. If any alternates are present, their packs are also considered.
public OpenObjectInAllPacks ( ICollection @out, GitSharp.Core.WindowCursor windowCursor, AnyObjectId objectId ) : void
@out ICollection
windowCursor GitSharp.Core.WindowCursor /// Temporary working space associated with the calling thread. ///
objectId AnyObjectId of object to search for.
리턴 void

OpenObjectInAllPacksImplementation() 공개 메소드

Open the object from all packs containing it. If any alternates are present, their packs are also considered.
public OpenObjectInAllPacksImplementation ( ICollection @out, GitSharp.Core.WindowCursor windowCursor, AnyObjectId objectId ) : void
@out ICollection
windowCursor GitSharp.Core.WindowCursor /// Temporary working space associated with the calling thread. ///
objectId AnyObjectId of object to search for.
리턴 void

close() 공개 메소드

Close any resources held by this database and its active alternates.
public close ( ) : void
리턴 void

closeAlternates() 공개 메소드

Fully close all loaded alternates and clear the alternate list.
public closeAlternates ( ) : void
리턴 void

closeAlternates() 보호된 메소드

protected closeAlternates ( ObjectDatabase alt ) : void
alt ObjectDatabase
리턴 void

closeSelf() 공개 메소드

Close any resources held by this database only; ignoring alternates. To fully close this database and its referenced alternates, the caller should instead invoke close().
public closeSelf ( ) : void
리턴 void

create() 공개 메소드

Initialize a new object database at this location.
public create ( ) : void
리턴 void

exists() 공개 메소드

Gets if this database is already created; If it returns false, the caller should invoke create to create this database location.
public exists ( ) : bool
리턴 bool

getAlternates() 공개 메소드

Get the alternate databases known to this database.
public getAlternates ( ) : GitSharp.Core.ObjectDatabase[]
리턴 GitSharp.Core.ObjectDatabase[]

hasObject() 공개 메소드

Does the requested object exist in this database? Alternates (if present) are searched automatically.
public hasObject ( AnyObjectId objectId ) : bool
objectId AnyObjectId identity of the object to test for existence of.
리턴 bool

hasObject1() 공개 추상적인 메소드

Fast half of hasObject(AnyObjectId).
public abstract hasObject1 ( AnyObjectId objectId ) : bool
objectId AnyObjectId /// Identity of the object to test for existence of. ///
리턴 bool

hasObject2() 공개 메소드

Slow half of hasObject(AnyObjectId).
public hasObject2 ( string objectName ) : bool
objectName string /// Identity of the object to test for existence of. ///
리턴 bool

loadAlternates() 공개 메소드

Load the list of alternate databases into memory. This method is invoked by getAlternates() if the alternate list has not yet been populated, or if closeAlternates() has been called on this instance and the alternate list is needed again. If the alternate array is empty, implementors should consider using the constant NoAlternates.
/// The alternate list could not be accessed. The empty alternate /// array will be assumed by the caller. ///
public loadAlternates ( ) : GitSharp.Core.ObjectDatabase[]
리턴 GitSharp.Core.ObjectDatabase[]

openObject() 공개 메소드

Open an object from this database. Alternates (if present) are searched automatically.
public openObject ( GitSharp.Core.WindowCursor curs, AnyObjectId objectId ) : GitSharp.Core.ObjectLoader
curs GitSharp.Core.WindowCursor /// Temporary working space associated with the calling thread. ///
objectId AnyObjectId Identity of the object to open.
리턴 GitSharp.Core.ObjectLoader

openObject1() 공개 추상적인 메소드

Fast half of openObject(WindowCursor, AnyObjectId).
public abstract openObject1 ( GitSharp.Core.WindowCursor curs, AnyObjectId objectId ) : GitSharp.Core.ObjectLoader
curs GitSharp.Core.WindowCursor /// temporary working space associated with the calling thread. ///
objectId AnyObjectId identity of the object to open.
리턴 GitSharp.Core.ObjectLoader

openObject2() 공개 메소드

Slow half of openObject(WindowCursor, AnyObjectId).
public openObject2 ( GitSharp.Core.WindowCursor curs, string objectName, AnyObjectId objectId ) : GitSharp.Core.ObjectLoader
curs GitSharp.Core.WindowCursor /// temporary working space associated with the calling thread. ///
objectName string Name of the object to open.
objectId AnyObjectId identity of the object to open.
리턴 GitSharp.Core.ObjectLoader

tryAgain1() 공개 메소드

true if the fast-half search should be tried again.
public tryAgain1 ( ) : bool
리턴 bool

프로퍼티 상세

NoAlternates 보호되어 있는 정적으로 프로퍼티

Constant indicating no alternate databases exist.
protected static ObjectDatabase[],GitSharp.Core NoAlternates
리턴 GitSharp.Core.ObjectDatabase[]