BadScript 2
Loading...
Searching...
No Matches
CommandLine.ParserExtensions Class Reference

Defines generic overloads for CommandLine.Parser.ParseArguments(IEnumerable<string>,Type[]) method. More...

Static Public Member Functions

static ParserResult< object > ParseArguments< T1, T2 > (this Parser parser, IEnumerable< string > args)
 Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.
 
static ParserResult< object > ParseArguments< T1, T2, T3 > (this Parser parser, IEnumerable< string > args)
 Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.
 
static ParserResult< object > ParseArguments< T1, T2, T3, T4 > (this Parser parser, IEnumerable< string > args)
 Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.
 
static ParserResult< object > ParseArguments< T1, T2, T3, T4, T5 > (this Parser parser, IEnumerable< string > args)
 Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.
 
static ParserResult< object > ParseArguments< T1, T2, T3, T4, T5, T6 > (this Parser parser, IEnumerable< string > args)
 Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.
 
static ParserResult< object > ParseArguments< T1, T2, T3, T4, T5, T6, T7 > (this Parser parser, IEnumerable< string > args)
 Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.
 
static ParserResult< object > ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8 > (this Parser parser, IEnumerable< string > args)
 Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.
 
static ParserResult< object > ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9 > (this Parser parser, IEnumerable< string > args)
 Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.
 
static ParserResult< object > ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10 > (this Parser parser, IEnumerable< string > args)
 Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.
 
static ParserResult< object > ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11 > (this Parser parser, IEnumerable< string > args)
 Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.
 
static ParserResult< object > ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12 > (this Parser parser, IEnumerable< string > args)
 Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.
 
static ParserResult< object > ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13 > (this Parser parser, IEnumerable< string > args)
 Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.
 
static ParserResult< object > ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > (this Parser parser, IEnumerable< string > args)
 Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.
 
static ParserResult< object > ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15 > (this Parser parser, IEnumerable< string > args)
 Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.
 
static ParserResult< object > ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16 > (this Parser parser, IEnumerable< string > args)
 Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.
 

Detailed Description

Defines generic overloads for CommandLine.Parser.ParseArguments(IEnumerable<string>,Type[]) method.

Definition at line 11 of file ParserExtensions.cs.

Member Function Documentation

◆ ParseArguments< T1, T2 >()

static ParserResult< object > CommandLine.ParserExtensions.ParseArguments< T1, T2 > ( this Parser  parser,
IEnumerable< string >  args 
)
static

Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.

Template Parameters
T1The type of the first verb.
T2The type of the second verb.
Parameters
parserA CommandLine.Parser instance.
argsA System.String array of command line arguments, normally supplied by application entry point.
Returns
A CommandLine.ParserResult<T> containing the appropriate instance with parsed values as a System.Object and a sequence of CommandLine.Error.
Exceptions
System.ArgumentNullExceptionThrown if one or more arguments are null.

All types must expose a parameterless constructor.

Definition at line 33 of file ParserExtensions.cs.

34 {
35 if (parser == null)
36 {
37 throw new ArgumentNullException("parser");
38 }
39
40 return parser.ParseArguments(args, typeof(T1), typeof(T2));
41 }

◆ ParseArguments< T1, T2, T3 >()

static ParserResult< object > CommandLine.ParserExtensions.ParseArguments< T1, T2, T3 > ( this Parser  parser,
IEnumerable< string >  args 
)
static

Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.

Template Parameters
T1The type of the first verb.
T2The type of the second verb.
T3The type of the third verb.
Parameters
parserA CommandLine.Parser instance.
argsA System.String array of command line arguments, normally supplied by application entry point.
Returns
A CommandLine.ParserResult<T> containing the appropriate instance with parsed values as a System.Object and a sequence of CommandLine.Error.
Exceptions
System.ArgumentNullExceptionThrown if one or more arguments are null.

All types must expose a parameterless constructor.

Definition at line 64 of file ParserExtensions.cs.

65 {
66 if (parser == null)
67 {
68 throw new ArgumentNullException("parser");
69 }
70
71 return parser.ParseArguments(args, typeof(T1), typeof(T2), typeof(T3));
72 }

◆ ParseArguments< T1, T2, T3, T4 >()

static ParserResult< object > CommandLine.ParserExtensions.ParseArguments< T1, T2, T3, T4 > ( this Parser  parser,
IEnumerable< string >  args 
)
static

Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.

Template Parameters
T1The type of the first verb.
T2The type of the second verb.
T3The type of the third verb.
T4The type of the fourth verb.
Parameters
parserA CommandLine.Parser instance.
argsA System.String array of command line arguments, normally supplied by application entry point.
Returns
A CommandLine.ParserResult<T> containing the appropriate instance with parsed values as a System.Object and a sequence of CommandLine.Error.
Exceptions
System.ArgumentNullExceptionThrown if one or more arguments are null.

All types must expose a parameterless constructor.

Definition at line 96 of file ParserExtensions.cs.

97 {
98 if (parser == null)
99 {
100 throw new ArgumentNullException("parser");
101 }
102
103 return parser.ParseArguments(args, typeof(T1), typeof(T2), typeof(T3), typeof(T4));
104 }

◆ ParseArguments< T1, T2, T3, T4, T5 >()

static ParserResult< object > CommandLine.ParserExtensions.ParseArguments< T1, T2, T3, T4, T5 > ( this Parser  parser,
IEnumerable< string >  args 
)
static

Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.

Template Parameters
T1The type of the first verb.
T2The type of the second verb.
T3The type of the third verb.
T4The type of the fourth verb.
T5The type of the fifth verb.
Parameters
parserA CommandLine.Parser instance.
argsA System.String array of command line arguments, normally supplied by application entry point.
Returns
A CommandLine.ParserResult<T> containing the appropriate instance with parsed values as a System.Object and a sequence of CommandLine.Error.
Exceptions
System.ArgumentNullExceptionThrown if one or more arguments are null.

All types must expose a parameterless constructor.

Definition at line 129 of file ParserExtensions.cs.

132 {
133 if (parser == null)
134 {
135 throw new ArgumentNullException("parser");
136 }
137
138 return parser.ParseArguments(args, typeof(T1), typeof(T2), typeof(T3), typeof(T4), typeof(T5));
139 }

◆ ParseArguments< T1, T2, T3, T4, T5, T6 >()

static ParserResult< object > CommandLine.ParserExtensions.ParseArguments< T1, T2, T3, T4, T5, T6 > ( this Parser  parser,
IEnumerable< string >  args 
)
static

Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.

Template Parameters
T1The type of the first verb.
T2The type of the second verb.
T3The type of the third verb.
T4The type of the fourth verb.
T5The type of the fifth verb.
T6The type of the sixth verb.
Parameters
parserA CommandLine.Parser instance.
argsA System.String array of command line arguments, normally supplied by application entry point.
Returns
A CommandLine.ParserResult<T> containing the appropriate instance with parsed values as a System.Object and a sequence of CommandLine.Error.
Exceptions
System.ArgumentNullExceptionThrown if one or more arguments are null.

All types must expose a parameterless constructor.

Definition at line 165 of file ParserExtensions.cs.

168 {
169 if (parser == null)
170 {
171 throw new ArgumentNullException("parser");
172 }
173
174 return parser.ParseArguments(args, typeof(T1), typeof(T2), typeof(T3), typeof(T4), typeof(T5), typeof(T6));
175 }

◆ ParseArguments< T1, T2, T3, T4, T5, T6, T7 >()

static ParserResult< object > CommandLine.ParserExtensions.ParseArguments< T1, T2, T3, T4, T5, T6, T7 > ( this Parser  parser,
IEnumerable< string >  args 
)
static

Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.

Template Parameters
T1The type of the first verb.
T2The type of the second verb.
T3The type of the third verb.
T4The type of the fourth verb.
T5The type of the fifth verb.
T6The type of the sixth verb.
T7The type of the seventh verb.
Parameters
parserA CommandLine.Parser instance.
argsA System.String array of command line arguments, normally supplied by application entry point.
Returns
A CommandLine.ParserResult<T> containing the appropriate instance with parsed values as a System.Object and a sequence of CommandLine.Error.
Exceptions
System.ArgumentNullExceptionThrown if one or more arguments are null.

All types must expose a parameterless constructor.

Definition at line 202 of file ParserExtensions.cs.

205 {
206 if (parser == null)
207 {
208 throw new ArgumentNullException("parser");
209 }
210
211 return parser.ParseArguments(args,
212 typeof(T1),
213 typeof(T2),
214 typeof(T3),
215 typeof(T4),
216 typeof(T5),
217 typeof(T6),
218 typeof(T7)
219 );
220 }

◆ ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8 >()

static ParserResult< object > CommandLine.ParserExtensions.ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8 > ( this Parser  parser,
IEnumerable< string >  args 
)
static

Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.

Template Parameters
T1The type of the first verb.
T2The type of the second verb.
T3The type of the third verb.
T4The type of the fourth verb.
T5The type of the fifth verb.
T6The type of the sixth verb.
T7The type of the seventh verb.
T8The type of the eighth verb.
Parameters
parserA CommandLine.Parser instance.
argsA System.String array of command line arguments, normally supplied by application entry point.
Returns
A CommandLine.ParserResult<T> containing the appropriate instance with parsed values as a System.Object and a sequence of CommandLine.Error.
Exceptions
System.ArgumentNullExceptionThrown if one or more arguments are null.

All types must expose a parameterless constructor.

Definition at line 248 of file ParserExtensions.cs.

251 {
252 if (parser == null)
253 {
254 throw new ArgumentNullException("parser");
255 }
256
257 return parser.ParseArguments(args,
258 typeof(T1),
259 typeof(T2),
260 typeof(T3),
261 typeof(T4),
262 typeof(T5),
263 typeof(T6),
264 typeof(T7),
265 typeof(T8)
266 );
267 }

◆ ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9 >()

static ParserResult< object > CommandLine.ParserExtensions.ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9 > ( this Parser  parser,
IEnumerable< string >  args 
)
static

Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.

Template Parameters
T1The type of the first verb.
T2The type of the second verb.
T3The type of the third verb.
T4The type of the fourth verb.
T5The type of the fifth verb.
T6The type of the sixth verb.
T7The type of the seventh verb.
T8The type of the eighth verb.
T9The type of the ninth verb.
Parameters
parserA CommandLine.Parser instance.
argsA System.String array of command line arguments, normally supplied by application entry point.
Returns
A CommandLine.ParserResult<T> containing the appropriate instance with parsed values as a System.Object and a sequence of CommandLine.Error.
Exceptions
System.ArgumentNullExceptionThrown if one or more arguments are null.

All types must expose a parameterless constructor.

Definition at line 296 of file ParserExtensions.cs.

299 {
300 if (parser == null)
301 {
302 throw new ArgumentNullException("parser");
303 }
304
305 return parser.ParseArguments(args,
306 typeof(T1),
307 typeof(T2),
308 typeof(T3),
309 typeof(T4),
310 typeof(T5),
311 typeof(T6),
312 typeof(T7),
313 typeof(T8),
314 typeof(T9)
315 );
316 }

◆ ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10 >()

static ParserResult< object > CommandLine.ParserExtensions.ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10 > ( this Parser  parser,
IEnumerable< string >  args 
)
static

Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.

Template Parameters
T1The type of the first verb.
T2The type of the second verb.
T3The type of the third verb.
T4The type of the fourth verb.
T5The type of the fifth verb.
T6The type of the sixth verb.
T7The type of the seventh verb.
T8The type of the eighth verb.
T9The type of the ninth verb.
T10The type of the tenth verb.
Parameters
parserA CommandLine.Parser instance.
argsA System.String array of command line arguments, normally supplied by application entry point.
Returns
A CommandLine.ParserResult<T> containing the appropriate instance with parsed values as a System.Object and a sequence of CommandLine.Error.
Exceptions
System.ArgumentNullExceptionThrown if one or more arguments are null.

All types must expose a parameterless constructor.

Definition at line 346 of file ParserExtensions.cs.

349 {
350 if (parser == null)
351 {
352 throw new ArgumentNullException("parser");
353 }
354
355 return parser.ParseArguments(args,
356 typeof(T1),
357 typeof(T2),
358 typeof(T3),
359 typeof(T4),
360 typeof(T5),
361 typeof(T6),
362 typeof(T7),
363 typeof(T8),
364 typeof(T9),
365 typeof(T10)
366 );
367 }

◆ ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11 >()

static ParserResult< object > CommandLine.ParserExtensions.ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11 > ( this Parser  parser,
IEnumerable< string >  args 
)
static

Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.

Template Parameters
T1The type of the first verb.
T2The type of the second verb.
T3The type of the third verb.
T4The type of the fourth verb.
T5The type of the fifth verb.
T6The type of the sixth verb.
T7The type of the seventh verb.
T8The type of the eighth verb.
T9The type of the ninth verb.
T10The type of the tenth verb.
T11The type of the eleventh verb.
Parameters
parserA CommandLine.Parser instance.
argsA System.String array of command line arguments, normally supplied by application entry point.
Returns
A CommandLine.ParserResult<T> containing the appropriate instance with parsed values as a System.Object and a sequence of CommandLine.Error.
Exceptions
System.ArgumentNullExceptionThrown if one or more arguments are null.

All types must expose a parameterless constructor.

Definition at line 398 of file ParserExtensions.cs.

401 {
402 if (parser == null)
403 {
404 throw new ArgumentNullException("parser");
405 }
406
407 return parser.ParseArguments(args,
408 typeof(T1),
409 typeof(T2),
410 typeof(T3),
411 typeof(T4),
412 typeof(T5),
413 typeof(T6),
414 typeof(T7),
415 typeof(T8),
416 typeof(T9),
417 typeof(T10),
418 typeof(T11)
419 );
420 }

◆ ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12 >()

static ParserResult< object > CommandLine.ParserExtensions.ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12 > ( this Parser  parser,
IEnumerable< string >  args 
)
static

Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.

Template Parameters
T1The type of the first verb.
T2The type of the second verb.
T3The type of the third verb.
T4The type of the fourth verb.
T5The type of the fifth verb.
T6The type of the sixth verb.
T7The type of the seventh verb.
T8The type of the eighth verb.
T9The type of the ninth verb.
T10The type of the tenth verb.
T11The type of the eleventh verb.
T12The type of the twelfth verb.
Parameters
parserA CommandLine.Parser instance.
argsA System.String array of command line arguments, normally supplied by application entry point.
Returns
A CommandLine.ParserResult<T> containing the appropriate instance with parsed values as a System.Object and a sequence of CommandLine.Error.
Exceptions
System.ArgumentNullExceptionThrown if one or more arguments are null.

All types must expose a parameterless constructor.

Definition at line 452 of file ParserExtensions.cs.

455 {
456 if (parser == null)
457 {
458 throw new ArgumentNullException("parser");
459 }
460
461 return parser.ParseArguments(args,
462 typeof(T1),
463 typeof(T2),
464 typeof(T3),
465 typeof(T4),
466 typeof(T5),
467 typeof(T6),
468 typeof(T7),
469 typeof(T8),
470 typeof(T9),
471 typeof(T10),
472 typeof(T11),
473 typeof(T12)
474 );
475 }

◆ ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13 >()

static ParserResult< object > CommandLine.ParserExtensions.ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13 > ( this Parser  parser,
IEnumerable< string >  args 
)
static

Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.

Template Parameters
T1The type of the first verb.
T2The type of the second verb.
T3The type of the third verb.
T4The type of the fourth verb.
T5The type of the fifth verb.
T6The type of the sixth verb.
T7The type of the seventh verb.
T8The type of the eighth verb.
T9The type of the ninth verb.
T10The type of the tenth verb.
T11The type of the eleventh verb.
T12The type of the twelfth verb.
T13The type of the thirteenth verb.
Parameters
parserA CommandLine.Parser instance.
argsA System.String array of command line arguments, normally supplied by application entry point.
Returns
A CommandLine.ParserResult<T> containing the appropriate instance with parsed values as a System.Object and a sequence of CommandLine.Error.
Exceptions
System.ArgumentNullExceptionThrown if one or more arguments are null.

All types must expose a parameterless constructor.

Definition at line 508 of file ParserExtensions.cs.

511 {
512 if (parser == null)
513 {
514 throw new ArgumentNullException("parser");
515 }
516
517 return parser.ParseArguments(args,
518 typeof(T1),
519 typeof(T2),
520 typeof(T3),
521 typeof(T4),
522 typeof(T5),
523 typeof(T6),
524 typeof(T7),
525 typeof(T8),
526 typeof(T9),
527 typeof(T10),
528 typeof(T11),
529 typeof(T12),
530 typeof(T13)
531 );
532 }

◆ ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 >()

static ParserResult< object > CommandLine.ParserExtensions.ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14 > ( this Parser  parser,
IEnumerable< string >  args 
)
static

Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.

Template Parameters
T1The type of the first verb.
T2The type of the second verb.
T3The type of the third verb.
T4The type of the fourth verb.
T5The type of the fifth verb.
T6The type of the sixth verb.
T7The type of the seventh verb.
T8The type of the eighth verb.
T9The type of the ninth verb.
T10The type of the tenth verb.
T11The type of the eleventh verb.
T12The type of the twelfth verb.
T13The type of the thirteenth verb.
T14The type of the fourteenth verb.
Parameters
parserA CommandLine.Parser instance.
argsA System.String array of command line arguments, normally supplied by application entry point.
Returns
A CommandLine.ParserResult<T> containing the appropriate instance with parsed values as a System.Object and a sequence of CommandLine.Error.
Exceptions
System.ArgumentNullExceptionThrown if one or more arguments are null.

All types must expose a parameterless constructor.

Definition at line 566 of file ParserExtensions.cs.

569 {
570 if (parser == null)
571 {
572 throw new ArgumentNullException("parser");
573 }
574
575 return parser.ParseArguments(args,
576 typeof(T1),
577 typeof(T2),
578 typeof(T3),
579 typeof(T4),
580 typeof(T5),
581 typeof(T6),
582 typeof(T7),
583 typeof(T8),
584 typeof(T9),
585 typeof(T10),
586 typeof(T11),
587 typeof(T12),
588 typeof(T13),
589 typeof(T14)
590 );
591 }

◆ ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15 >()

static ParserResult< object > CommandLine.ParserExtensions.ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15 > ( this Parser  parser,
IEnumerable< string >  args 
)
static

Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.

Template Parameters
T1The type of the first verb.
T2The type of the second verb.
T3The type of the third verb.
T4The type of the fourth verb.
T5The type of the fifth verb.
T6The type of the sixth verb.
T7The type of the seventh verb.
T8The type of the eighth verb.
T9The type of the ninth verb.
T10The type of the tenth verb.
T11The type of the eleventh verb.
T12The type of the twelfth verb.
T13The type of the thirteenth verb.
T14The type of the fourteenth verb.
T15The type of the fifteenth verb.
Parameters
parserA CommandLine.Parser instance.
argsA System.String array of command line arguments, normally supplied by application entry point.
Returns
A CommandLine.ParserResult<T> containing the appropriate instance with parsed values as a System.Object and a sequence of CommandLine.Error.
Exceptions
System.ArgumentNullExceptionThrown if one or more arguments are null.

All types must expose a parameterless constructor.

Definition at line 626 of file ParserExtensions.cs.

628 {
629 if (parser == null)
630 {
631 throw new ArgumentNullException("parser");
632 }
633
634 return parser.ParseArguments(args,
635 typeof(T1),
636 typeof(T2),
637 typeof(T3),
638 typeof(T4),
639 typeof(T5),
640 typeof(T6),
641 typeof(T7),
642 typeof(T8),
643 typeof(T9),
644 typeof(T10),
645 typeof(T11),
646 typeof(T12),
647 typeof(T13),
648 typeof(T14),
649 typeof(T15)
650 );
651 }

◆ ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16 >()

static ParserResult< object > CommandLine.ParserExtensions.ParseArguments< T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, T16 > ( this Parser  parser,
IEnumerable< string >  args 
)
static

Parses a string array of command line arguments for verb commands scenario, constructing the proper instance from types as generic arguments. Grammar rules are defined decorating public properties with appropriate attributes. The CommandLine.VerbAttribute must be applied to types in the array.

Template Parameters
T1The type of the first verb.
T2The type of the second verb.
T3The type of the third verb.
T4The type of the fourth verb.
T5The type of the fifth verb.
T6The type of the sixth verb.
T7The type of the seventh verb.
T8The type of the eighth verb.
T9The type of the ninth verb.
T10The type of the tenth verb.
T11The type of the eleventh verb.
T12The type of the twelfth verb.
T13The type of the thirteenth verb.
T14The type of the fourteenth verb.
T15The type of the fifteenth verb.
T16The type of the sixteenth verb.
Parameters
parserA CommandLine.Parser instance.
argsA System.String array of command line arguments, normally supplied by application entry point.
Returns
A CommandLine.ParserResult<T> containing the appropriate instance with parsed values as a System.Object and a sequence of CommandLine.Error.
Exceptions
System.ArgumentNullExceptionThrown if one or more arguments are null.

All types must expose a parameterless constructor.

Definition at line 687 of file ParserExtensions.cs.

689 {
690 if (parser == null)
691 {
692 throw new ArgumentNullException("parser");
693 }
694
695 return parser.ParseArguments(args,
696 typeof(T1),
697 typeof(T2),
698 typeof(T3),
699 typeof(T4),
700 typeof(T5),
701 typeof(T6),
702 typeof(T7),
703 typeof(T8),
704 typeof(T9),
705 typeof(T10),
706 typeof(T11),
707 typeof(T12),
708 typeof(T13),
709 typeof(T14),
710 typeof(T15),
711 typeof(T16)
712 );
713 }

The documentation for this class was generated from the following file: