Table of Contents

Class CommandLineValue

Namespace
Ubiquity.CommandLineParsing
Assembly
Ubiquity.CommandlineParsing.dll

Command line argument value.

public class CommandLineValue : ICommandLineArgument
Inheritance
CommandLineValue
Implements
Inherited Members
Extension Methods

Remarks

A value is either a positional argument (with outer most quoting removed) or the value of an option.

Constructors

CommandLineValue(string)

Initializes a new instance of the CommandLineValue class.

public CommandLineValue(string text)

Parameters

text string

Full text of the value (without the outermost quotes that may be applied to allow spaces, etc...)

Properties

Text

Gets the full text of argument.

public string Text { get; }

Property Value

string

Remarks

This is generally used for debugging and reporting errors to the user so that the actual full text of an invalid option is available to aid in clarity for the user.

For a switch/option the full text of the value includes the leading switch, the name of the option any value separator and the value. For positional arguments it includes the full string (without the outermost quotes, if any, to allow spaces, etc.. in the value).

Methods

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

A string that represents the current object.