private static IProcess GetProcess(string[] args, out int status) { var commandSwitches = new CommandSwitches(args, out status); if (status != 0) { return(null); } if (commandSwitches.CompareMode) { return(new SourceComparisonMode(commandSwitches)); } Console.WriteLine( "Mode not set (-draw, -compare, or -filter expected)."); status = 1; return(null); }
public SourceComparisonMode(CommandSwitches commandSwitches) { CommandSwitches = commandSwitches ?? throw new ArgumentNullException(nameof(commandSwitches)); // This information is already printed to the output stream. Multithreaded = CommandSwitches.Multithreaded; Verbose = CommandSwitches.Verbose; TimeStamp = CommandSwitches.TimeStamp; LogPath = CommandSwitches.LogPath; Console.WriteLine(); Console.WriteLine("Source Comparison Mode:"); FilteredPath = ReadFilteredPath(); UnfilteredPath = ReadUnfilteredPath(); SpitzerPath = ReadSpitzerPath(); OutputPath = ReadOutputPath(); SearchRadius = ReadSearchRadius(); Color1 = ReadColor1(); Color2 = ReadColor2(); Color3 = ReadColor3(); }