/// <summary> /// Parse the command line options for this extension. /// </summary> /// <param name="type">The active harvester type.</param> /// <param name="args">The option arguments.</param> public override void ParseOptions(string type, string[] args) { bool active = false; HarvesterExtension harvesterExtension = null; IIsHarvesterMutator iisHarvesterMutator = new IIsHarvesterMutator(); // select the harvester switch (type) { case "website": harvesterExtension = new IIsWebSiteHarvester(); active = true; break; } // set default settings iisHarvesterMutator.SetUniqueIdentifiers = true; // parse the options foreach (string arg in args) { if (null == arg || 0 == arg.Length) // skip blank arguments { continue; } if ('-' == arg[0] || '/' == arg[0]) { string parameter = arg.Substring(1); if ("suid" == parameter) { iisHarvesterMutator.SetUniqueIdentifiers = false; } } } // set the appropriate harvester extension if (active) { this.Core.Harvester.Extension = harvesterExtension; this.Core.Mutator.AddExtension(iisHarvesterMutator); this.Core.Mutator.AddExtension(new IIsFinalizeHarvesterMutator()); this.Core.Mutator.AddExtension(new UtilFinalizeHarvesterMutator()); } }