C# Class Mercurial.PersistentClient

This class implements IClient by spinning up an instance when first instantiated, and keeping the instance around and communicating with it over standard input and output, using the new "command server mode" introduced in Mercurial 1.9.
Inheritance: IClient, IDisposable
Afficher le fichier Open project: TargetProcess/Mercurial-Plugin Class Usage Examples

Méthodes publiques

Méthode Description
CancelExecuting ( ) : void

Stops command executing.

Dispose ( ) : void

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

Execute ( IMercurialCommand command ) : void

Executes the given IMercurialCommand command against the Mercurial repository.

IsSupported ( string repositoryPath ) : bool

Determine if this class is supported by the given repository and current Mercurial client version.

PersistentClient ( string repositoryPath ) : System

Initializes a new instance of the PersistentClient class.

Private Methods

Méthode Description
DecodeInitialBlock ( ) : void

Decodes the initial block that Mercurial outputs when it is spun up.

StartPersistentMercurialClient ( ) : void

This spins up a Mercurial client in command server mode for the repository.

StopPersistentMercurialClient ( ) : void

This spins down the Mercurial client that was spun up by StartPersistentMercurialClient.

Method Details

CancelExecuting() public méthode

Stops command executing.
public CancelExecuting ( ) : void
Résultat void

Dispose() public méthode

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
public Dispose ( ) : void
Résultat void

Execute() public méthode

Executes the given IMercurialCommand command against the Mercurial repository.
/// is null. /// /// HG did not complete within the allotted time. ///
public Execute ( IMercurialCommand command ) : void
command IMercurialCommand /// The command to execute. ///
Résultat void

IsSupported() public static méthode

Determine if this class is supported by the given repository and current Mercurial client version.
/// is null or empty. ///
public static IsSupported ( string repositoryPath ) : bool
repositoryPath string /// The path to the repository to check supportability for. ///
Résultat bool

PersistentClient() public méthode

Initializes a new instance of the PersistentClient class.
/// is null or empty. /// /// The is not supported for the specified repository path, /// or the current Mercurial client. ///
public PersistentClient ( string repositoryPath ) : System
repositoryPath string /// The path to the repository this will handle. ///
Résultat System