ParseOptionsAttributeNameValueSeparators Property
Gets or sets the characters used to separate the name and the value of an argument.
Namespace: Ookii.CommandLineAssembly: Ookii.CommandLine (in Ookii.CommandLine.dll) Version: 4.2.0+a4d3631e4dcc0970081ed435288efdebc1325f83
public char[]? NameValueSeparators { get; set; }
Public Property NameValueSeparators As Char()
Get
Set
Dim instance As ParseOptionsAttribute
Dim value As Char()
value = instance.NameValueSeparators
instance.NameValueSeparators = value
public:
property array<wchar_t>^ NameValueSeparators {
array<wchar_t>^ get ();
void set (array<wchar_t>^ value);
}
Property Value
Char
The characters used to separate the name and the value of an argument, or
to use the default value from the
CommandLineParserGetDefaultNameValueSeparators
method, which is a colon ':' and an equals sign '='. The default value is
.
These characters are used to separate the name and the value if both are provided as
a single argument to the application, e.g. -sample:value or -sample=value
if the default value is used.
The character chosen here cannot be used in the name of any parameter. Therefore,
it's usually best to choose a non-alphanumeric value such as the colon or equals sign.
The character can appear in argument values (e.g. -sample:foo:bar is fine, in which
case the value is "foo:bar").
Do not pick a white-space character as the separator. Doing this only works if the
whitespace character is part of the argument, which usually means it needs to be
quoted or escaped when invoking your application. Instead, use the
AllowWhiteSpaceValueSeparator property to control whether white space
is allowed as a separator.
This value can be overridden by the ParseOptionsNameValueSeparators
property.