C# Class NuGetConsole.Host.PowerShell.Implementation.PowerShellHost

Inheritance: IHost, IPathExpansion, IDisposable
显示文件 Open project: themotleyfool/NuGet

Private Properties

Property Type Description
AddPathToEnvironment void
DisplayDisclaimerAndHelpText void
EvaluatePrompt string
ExecuteInitScripts void
Initialize void
UpdateWorkingDirectory void
WriteErrorLine void
WriteLine void

Public Methods

Method Description
Abort ( ) : void
Dispose ( ) : void
Execute ( IConsole console, string command ) : bool
GetAvailableProjects ( ) : string[]
GetExpansions ( string line, string lastWord ) : string[]
GetPackageSources ( ) : string[]
GetPathExpansions ( string line ) : SimpleExpansion
SetDefaultProjectIndex ( int selectedIndex ) : void
SetDefaultRunspace ( ) : void

Protected Methods

Method Description
ExecuteHost ( string fullCommand, string command ) : bool
OnExecuteCommandEnd ( ) : void
PowerShellHost ( string name, IRunspaceManager runspaceManager ) : System
ReportError ( ErrorRecord record ) : void
ReportError ( Exception exception ) : void
SetSyncModeOnHost ( bool isSync ) : void

Private Methods

Method Description
AddPathToEnvironment ( string path ) : void
DisplayDisclaimerAndHelpText ( ) : void
EvaluatePrompt ( ) : string
ExecuteInitScripts ( ) : void
Initialize ( IConsole console ) : void
UpdateWorkingDirectory ( ) : void
WriteErrorLine ( string message ) : void
WriteLine ( string message = "" ) : void

Method Details

Abort() public method

public Abort ( ) : void
return void

Dispose() public method

public Dispose ( ) : void
return void

Execute() public method

public Execute ( IConsole console, string command ) : bool
console IConsole
command string
return bool

ExecuteHost() protected abstract method

protected abstract ExecuteHost ( string fullCommand, string command ) : bool
fullCommand string
command string
return bool

GetAvailableProjects() public method

public GetAvailableProjects ( ) : string[]
return string[]

GetExpansions() public method

public GetExpansions ( string line, string lastWord ) : string[]
line string
lastWord string
return string[]

GetPackageSources() public method

public GetPackageSources ( ) : string[]
return string[]

GetPathExpansions() public method

public GetPathExpansions ( string line ) : SimpleExpansion
line string
return SimpleExpansion

OnExecuteCommandEnd() protected method

protected OnExecuteCommandEnd ( ) : void
return void

PowerShellHost() protected method

protected PowerShellHost ( string name, IRunspaceManager runspaceManager ) : System
name string
runspaceManager IRunspaceManager
return System

ReportError() protected method

protected ReportError ( ErrorRecord record ) : void
record System.Management.Automation.ErrorRecord
return void

ReportError() protected method

protected ReportError ( Exception exception ) : void
exception System.Exception
return void

SetDefaultProjectIndex() public method

public SetDefaultProjectIndex ( int selectedIndex ) : void
selectedIndex int
return void

SetDefaultRunspace() public method

public SetDefaultRunspace ( ) : void
return void

SetSyncModeOnHost() protected method

protected SetSyncModeOnHost ( bool isSync ) : void
isSync bool
return void