Show / Hide Table of Contents

Class CommandManager

Command manager

Inheritance
object
CommandManager
Inherited Members
object.GetType()
object.MemberwiseClone()
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
Namespace: PayrollEngine.Client.Command
Assembly: PayrollEngine.Client.Core.dll
Syntax
public class CommandManager

Constructors

CommandManager(ICommandConsole, ILogger)

Command manager

Declaration
public CommandManager(ICommandConsole console, ILogger logger = null)
Parameters
Type Name Description
ICommandConsole console
ILogger logger

Properties

HasCommands

Test for any command

Declaration
public bool HasCommands { get; }
Property Value
Type Description
bool

Methods

ExecuteAsync(ICommand, PayrollHttpClient)

Execute specific command using the environment command line arguments

Declaration
public Task<int> ExecuteAsync(ICommand command, PayrollHttpClient httpClient = null)
Parameters
Type Name Description
ICommand command
PayrollHttpClient httpClient
Returns
Type Description
Task<int>

Exit code

ExecuteAsync(PayrollHttpClient)

Execute command using the environment command line arguments

Declaration
public Task<int> ExecuteAsync(PayrollHttpClient httpClient = null)
Parameters
Type Name Description
PayrollHttpClient httpClient
Returns
Type Description
Task<int>

Exit code

GetCommand(string)

Get command by name

Declaration
public ICommand GetCommand(string name)
Parameters
Type Name Description
string name

Command name

Returns
Type Description
ICommand

GetCommandLineCommand()

Get command line command

Declaration
public ICommand GetCommandLineCommand()
Returns
Type Description
ICommand

GetCommands()

List of available commands

Declaration
public List<ICommand> GetCommands()
Returns
Type Description
List<ICommand>

RegisterAssembly(Assembly)

Register assembly commands

Declaration
public void RegisterAssembly(Assembly assembly)
Parameters
Type Name Description
Assembly assembly

Source assembly

Extension Methods

ConsoleExtensions.WriteProperties(object, bool)
ValueTypeExtensions.GetValueType(object)
ObjectInfo.GetPropertyValue(object, string)
ObjectInfo.GetPropertyValue<T>(object, string, T)
ObjectInfo.ResolvePropertyValue(object, string)
ObjectInfo.SetPropertyValue(object, string, object)
☀
☾
Back to top Generated by DocFX