2 instantiations of CommandProcessorOptions
dotnet-svcutil-lib (2)
CommandLineParser.cs (1)
124var options = new CommandProcessorOptions();
CommandProcessorOptions.cs (1)
137CommandProcessorOptions cmdOptions = new CommandProcessorOptions();
108 references to CommandProcessorOptions
dotnet-svcutil-lib (106)
CodeDomFixup\CodeFixup.cs (1)
26public abstract void Fixup(CommandProcessorOptions options);
CodeDomFixup\IFixup.cs (1)
9void Fixup(CommandProcessorOptions options);
CodeDomFixup\MetadataFixup.cs (1)
61public void Fixup(CommandProcessorOptions options)
CodeDomFixup\VisitorFixup.cs (2)
12private static CodeDomVisitor[] GetVisitors(ServiceContractGenerator generator, CommandProcessorOptions options) 42public override void Fixup(CommandProcessorOptions options)
CodeDomFixup\WcfCodeGenerationExtension.cs (3)
20private CommandProcessorOptions _options; 22public WcfCodeGenerationExtension(CommandProcessorOptions options) 114private static void RunFixups(IFixup[] fixups, CommandProcessorOptions options)
CodeSerializer.cs (4)
28internal CodeSerializer(CommandProcessorOptions options, IEnumerable<MetadataSection> inputMetadata) 32_outputFilePath = OutputPathHelper.BuildFilePath(s_defaultFileName, options.OutputDir.FullName, outputFilename, extension, CommandProcessorOptions.Switches.OutputFile.Name); 121internal static string GetOutputFileExtension(CommandProcessorOptions options) 131internal static string GetOutputFileName(CommandProcessorOptions options, IEnumerable<MetadataSection> metadataSections)
CommandLineParser.cs (4)
122internal static CommandProcessorOptions ParseCommand(string[] cmd) 124var options = new CommandProcessorOptions(); 141SetValue(options, CommandProcessorOptions.InputsKey, Environment.ExpandEnvironmentVariables(arg)); 193private static void SetValue(CommandProcessorOptions options, string optionName, object value)
CommandProcessorOptions.cs (16)
25public override string Json { get { return Serialize<CommandProcessorOptions, OptionsSerializer<CommandProcessorOptions>>(); } } 116public static new CommandProcessorOptions FromFile(string filePath, bool throwOnError = true) 118return FromFile<CommandProcessorOptions>(filePath, throwOnError); 121public static bool TryFromFile(string filePath, out CommandProcessorOptions options) 126options = FromFile<CommandProcessorOptions>(filePath, throwOnError: false); 135internal static async Task<CommandProcessorOptions> ParseArgumentsAsync(string[] args, ILogger logger, CancellationToken cancellationToken) 137CommandProcessorOptions cmdOptions = new CommandProcessorOptions(); 147TryFromFile(fileUri.LocalPath, out var fileOptions) && fileOptions.GetOptions().Count() > 0) 485if (updateFileName.Equals(CommandProcessorOptions.SvcutilParamsFileName, RuntimeEnvironmentHelper.FileStringComparison) || 486updateFileName.Equals(CommandProcessorOptions.WCFCSParamsFileName, RuntimeEnvironmentHelper.FileStringComparison)) 498var paramsFiles = jsonFiles.Except(excludeJsonFiles).Where(fn => Path.GetFileName(fn).Equals(CommandProcessorOptions.SvcutilParamsFileName, RuntimeEnvironmentHelper.FileStringComparison) || 499Path.GetFileName(fn).Equals(CommandProcessorOptions.WCFCSParamsFileName, RuntimeEnvironmentHelper.FileStringComparison)); 523var svcutilParmasFile = Path.Combine(projectDir, this.UpdateServiceReferenceFolder, CommandProcessorOptions.SvcutilParamsFileName); 526var wcfcsParamsFile = Path.Combine(projectDir, this.UpdateServiceReferenceFolder, CommandProcessorOptions.WCFCSParamsFileName); 543if (Path.GetFileName(paramsFilePath).Equals(CommandProcessorOptions.WCFCSParamsFileName))
HelpGenerator.cs (50)
49ArgumentInfo.CreateParameterHelpInfo(CommandProcessorOptions.Switches.OutputDirectory.Name, SR.ParametersDirectory, string.Format(SR.HelpDirectoryFormat, CommandProcessorOptions.Switches.OutputDirectory.Abbreviation)), 50ArgumentInfo.CreateFlagHelpInfo( CommandProcessorOptions.Switches.NoLogo.Name, string.Format(SR.HelpNologoFormat, CommandProcessorOptions.Switches.NoLogo.Abbreviation)), 51ArgumentInfo.CreateParameterHelpInfo(CommandProcessorOptions.Switches.Verbosity.Name, SR.ParametersVerbosity, string.Format(SR.HelpVerbosityFormat, string.Join(", ", System.Enum.GetNames(typeof(Verbosity))), CommandProcessorOptions.Switches.Verbosity.Abbreviation)), 52ArgumentInfo.CreateFlagHelpInfo( CommandProcessorOptions.Switches.Help.Name, string.Format(SR.HelpHelpFormat, CommandProcessorOptions.Switches.Help.Abbreviation)), 53ArgumentInfo.CreateParameterHelpInfo(CommandProcessorOptions.Switches.ProjectFile.Name, SR.ParametersProjectFile, string.Format(SR.HelpProjectFileFormat, CommandProcessorOptions.Switches.ProjectFile.Abbreviation)), 54ArgumentInfo.CreateParameterHelpInfo(CommandProcessorOptions.Switches.OutputFile.Name, SR.ParametersOut, string.Format(SR.HelpOutFormat, CommandProcessorOptions.Switches.OutputFile.Abbreviation)), 55ArgumentInfo.CreateParameterHelpInfo(CommandProcessorOptions.Switches.Namespace.Name, SR.ParametersNamespace, string.Format(SR.HelpNamespaceFormat, CommandProcessorOptions.Switches.Namespace.Abbreviation), true), 56ArgumentInfo.CreateFlagHelpInfo( CommandProcessorOptions.Switches.MessageContract.Name, string.Format(SR.HelpMessageContractFormat, CommandProcessorOptions.Switches.MessageContract.Abbreviation), true), 57ArgumentInfo.CreateFlagHelpInfo( CommandProcessorOptions.Switches.EnableDataBinding.Name, string.Format(SR.HelpEnableDataBindingFormat, CommandProcessorOptions.Switches.EnableDataBinding.Abbreviation)), 58ArgumentInfo.CreateFlagHelpInfo( CommandProcessorOptions.Switches.Internal.Name, string.Format(SR.HelpInternalFormat, CommandProcessorOptions.Switches.Internal.Abbreviation)), 59ArgumentInfo.CreateParameterHelpInfo(CommandProcessorOptions.Switches.Reference.Name, SR.ParametersReference, string.Format(SR.HelpReferenceCodeGenerationFormat, CommandProcessorOptions.Switches.Reference.Abbreviation), true), 60ArgumentInfo.CreateFlagHelpInfo( CommandProcessorOptions.Switches.NoTypeReuse.Name, string.Format(SR.HelpNoTypeReuseFormat, CommandProcessorOptions.Switches.NoTypeReuse.Abbreviation, CommandProcessorOptions.Switches.Reference.Name, CommandProcessorOptions.Switches.CollectionType.Name)), 61ArgumentInfo.CreateParameterHelpInfo(CommandProcessorOptions.Switches.CollectionType.Name, SR.ParametersCollectionType, string.Format(SR.HelpCollectionTypeFormat, CommandProcessorOptions.Switches.CollectionType.Abbreviation)), 62ArgumentInfo.CreateParameterHelpInfo(CommandProcessorOptions.Switches.ExcludeType.Name, SR.ParametersExcludeType, string.Format(SR.HelpExcludeTypeCodeGenerationFormat, CommandProcessorOptions.Switches.ExcludeType.Abbreviation)), 63ArgumentInfo.CreateFlagHelpInfo( CommandProcessorOptions.Switches.NoStdlib.Name, string.Format(SR.HelpNostdlibFormat, CommandProcessorOptions.Switches.NoStdlib.Abbreviation)), 64ArgumentInfo.CreateParameterHelpInfo(CommandProcessorOptions.Switches.Serializer.Name, SerializerMode.Auto.ToString(), string.Format(SR.HelpAutoSerializerFormat, CommandProcessorOptions.Switches.Serializer.Abbreviation), true), 65ArgumentInfo.CreateParameterHelpInfo(CommandProcessorOptions.Switches.Serializer.Name, SerializerMode.DataContractSerializer.ToString(), SR.HelpDataContractSerializer), 66ArgumentInfo.CreateParameterHelpInfo(CommandProcessorOptions.Switches.Serializer.Name, SerializerMode.XmlSerializer.ToString(), SR.HelpXmlSerializer), 67ArgumentInfo.CreateFlagHelpInfo( CommandProcessorOptions.Switches.Sync.Name, string.Format(SR.HelpSyncFormat, CommandProcessorOptions.Switches.Sync.Abbreviation)), 68ArgumentInfo.CreateFlagHelpInfo( CommandProcessorOptions.Switches.Wrapped.Name, string.Format(SR.HelpWrappedFormat, CommandProcessorOptions.Switches.Wrapped.Abbreviation)), 69ArgumentInfo.CreateParameterHelpInfo(CommandProcessorOptions.Switches.Update.Name, SR.ParametersWebServiceReferenceName, string.Format(SR.HelpUpdateWebServiceReferenceFormat, CommandProcessorOptions.Switches.Update.Abbreviation)), 70ArgumentInfo.CreateParameterHelpInfo(CommandProcessorOptions.Switches.RuntimeIdentifier.Name, SR.ParametersRuntimeIdentifier, string.Format(SR.HelpRuntimeIdentifierFormat, CommandProcessorOptions.Switches.RuntimeIdentifier.Abbreviation)), 71ArgumentInfo.CreateParameterHelpInfo(CommandProcessorOptions.Switches.TargetFramework.Name, SR.ParametersTargetFramework, string.Format(SR.HelpTargetFrameworkFormat, CommandProcessorOptions.Switches.TargetFramework.Abbreviation)), 72ArgumentInfo.CreateFlagHelpInfo( CommandProcessorOptions.Switches.AcceptCertificate.Name, string.Format(SR.HelpAcceptCertificateFormat, CommandProcessorOptions.Switches.AcceptCertificate.Abbreviation)), 73ArgumentInfo.CreateFlagHelpInfo( CommandProcessorOptions.Switches.ServiceContract.Name, string.Format(SR.HelpServiceContractFormat, CommandProcessorOptions.Switches.ServiceContract.Abbreviation))
ImportModule.cs (10)
32private CommandProcessorOptions _options; 42internal ImportModule(CommandProcessorOptions options, ServiceDescriptor serviceDescriptor, WsdlImporter importer) 208internal static ServiceContractGenerator CreateServiceContractGenerator(CommandProcessorOptions options, CodeCompileUnit codeCompileUnit) 228private static void SetContractGeneratorOptions(CommandProcessorOptions options, ServiceContractGenerator contractGenerator) 257public static void RemoveUnneededSerializers(CommandProcessorOptions options, ServiceDescriptor serviceDescriptor, Collection<IWsdlImportExtension> wsdlImportExtensions) 283public static void ConfigureSerializers(CommandProcessorOptions options, CodeCompileUnit codeCompileUnit, WsdlImporter importer) 304internal static DcNS.XsdDataContractImporter CreateDCImporter(CommandProcessorOptions options, CodeCompileUnit codeCompileUnit) 312private static DcNS.ImportOptions CreateDCImportOptions(CommandProcessorOptions options) 332private static void AddStateForXmlSerializerImport(CommandProcessorOptions options, WsdlImporter importer, CodeCompileUnit codeCompileUnit) 356private static void AddStateForDataContractSerializerImport(CommandProcessorOptions options, WsdlImporter importer, CodeCompileUnit codeCompileUnit)
OutputPathHelper.cs (2)
94throw new ToolArgumentException(string.Format(SR.ErrPathTooLongFormat, path, CommandProcessorOptions.Switches.OutputDirectory.Name, option), ptle); 98throw new ToolArgumentException(string.Format(SR.ErrPathTooLongDirOnlyFormat, path, CommandProcessorOptions.Switches.OutputDirectory.Name), ptle);
Tool.cs (10)
79CommandProcessorOptions options = null; 85options = await CommandProcessorOptions.ParseArgumentsAsync(args, logger, cancellationToken); 198internal static async Task<ToolExitCode> RunAsync(CommandProcessorOptions options, CancellationToken cancellationToken) 263private static bool CanAddProjectReferences(CommandProcessorOptions options) 271private static async Task<bool> AddProjectReferencesAsync(MSBuildProj project, CommandProcessorOptions options, CancellationToken cancellationToken) 313private static async Task GenerateParamsFileAsync(CommandProcessorOptions options, ILogger logger, CancellationToken cancellationToken) 329var paramsFile = Path.Combine(options.OutputDir.FullName, CommandProcessorOptions.SvcutilParamsFileName); 335private static void ThrowOnValidationErrors(CommandProcessorOptions options) 345private static async Task<int> ProcessExceptionAsync(Exception ex, CommandProcessorOptions options) 438private static void ValidateUICulture(CommandProcessorOptions options)
ToolConsole.cs (2)
31public static void Init(CommandProcessorOptions options) 53toolError.AppendLine(string.Format(SR.MoreHelpFormat, CommandProcessorOptions.Switches.Help.Abbreviation));
dotnet-svcutil-lib.Tests (2)
UnitTest.cs (2)
248var cmdOptions = CommandParser.ParseCommand(args); 293var cmdOptions = CommandParser.ParseCommand(args);