Class ParsedArguments
A set of parsed arguments from a Command given its CommandDefinition.
Inherited Members
Namespace: Petabridge.Cmd.Common
Assembly: Petabridge.Cmd.Common.dll
Syntax
public sealed class ParsedArguments
Constructors
ParsedArguments(IReadOnlyDictionary<string, IReadOnlyList<string>>)
Declaration
public ParsedArguments(IReadOnlyDictionary<string, IReadOnlyList<string>> allArguments)
Parameters
Type | Name | Description |
---|---|---|
IReadOnlyDictionary<string, IReadOnlyList<string>> | allArguments |
Fields
Empty
Declaration
public static readonly ParsedArguments Empty
Field Value
Type | Description |
---|---|
ParsedArguments |
Properties
AllArguments
Declaration
public IReadOnlyDictionary<string, IReadOnlyList<string>> AllArguments { get; }
Property Value
Type | Description |
---|---|
IReadOnlyDictionary<string, IReadOnlyList<string>> |
Methods
ArgumentValues(string)
Retrieve the values for the provided argument.
Declaration
public IReadOnlyList<string> ArgumentValues(string argumentName)
Parameters
Type | Name | Description |
---|---|---|
string | argumentName | The name of the argument. |
Returns
Type | Description |
---|---|
IReadOnlyList<string> | If the argument was not set by this Command, we will return an empty List<T>. |
IsArgumentSet(string)
Check to see if this argument was set.
Declaration
public bool IsArgumentSet(string argumentName)
Parameters
Type | Name | Description |
---|---|---|
string | argumentName | The name of the argument. |
Returns
Type | Description |
---|---|
bool |
|