Пример #1
0
 private void InitializeRequiredNamedArguments()
 {
     RequiredNamedArguments.UnionWith(
         LongNameArguments.Values
         .Where(a => a.Required)
         .Select(a => a.Name));
     RequiredNamedArguments.UnionWith(
         ShortNameArguments.Values
         .Where(a => a.Required)
         .Select(a => a.Name));
 }
Пример #2
0
 internal void ProcessArguments()
 {
     foreach (var arg in PendingNamedArguments)
     {
         if (arg.ShortName.HasValue)
         {
             ShortNameArguments.Add(arg.ShortName.Value, arg);
         }
         if (arg.LongName != null)
         {
             LongNameArguments.Add(arg.LongName, arg);
         }
         if (arg.Required)
         {
             RequiredNamedArguments.Add(arg.Name);
         }
     }
 }