static CmdLine() { // setup our supported list of cmdline switches _supportedSwitches = CmdLineSwitches.Init( CustomSwitch.Build(SwitchNames.Update), CustomSwitch.Build(SwitchNames.Feed), CustomSwitch.Build(SwitchNames.Profile), CustomSwitch.Build(SwitchNames.Username), CustomSwitch.Build(SwitchNames.Password), CustomSwitch.Build(SwitchNames.Install, a => a.Add("install")), CustomSwitch.Build(SwitchNames.Uninstall, a => a.Add("uninstall"))); }
public void IfSupplied(CmdLineSwitches switches, Action <CustomSwitch> switchAction) { switches.Intersect(this).ForEach(switchAction); }