แก้ไข

แชร์ผ่าน


DirectiveCollection Class

Definition

A collection of directives parsed from a command line.

public ref class DirectiveCollection : System::Collections::Generic::IEnumerable<System::Collections::Generic::KeyValuePair<System::String ^, System::Collections::Generic::IEnumerable<System::String ^> ^>>
public class DirectiveCollection : System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<string,System.Collections.Generic.IEnumerable<string>>>
type DirectiveCollection = class
    interface seq<KeyValuePair<string, seq<string>>>
    interface IEnumerable
Public Class DirectiveCollection
Implements IEnumerable(Of KeyValuePair(Of String, IEnumerable(Of String)))
Inheritance
DirectiveCollection
Implements

Remarks

A directive is specified on the command line using square brackets, containing no spaces and preceding other tokens unless they are also directives. In the following example, two directives are present, directive-one and directive-two: > myapp [directive-one] [directive-two:value] arg1 arg2 The second has a value specified as well, value. Directive values can be read by calling using TryGetValues(String, IReadOnlyList<String>).

Constructors

DirectiveCollection()

Methods

Contains(String)

Gets a value determining whether a directive with the specified name was parsed.

GetEnumerator()

Returns an enumerator that iterates through the collection.

TryGetValues(String, IReadOnlyList<String>)

Gets the values specified for a given directive. A return value indicates whether the specified directive name was present.

Explicit Interface Implementations

IEnumerable.GetEnumerator()

Returns an enumerator that iterates through a collection.

Applies to