201 references to AppendSwitchIfNotNull
Microsoft.Build.Tasks.CodeAnalysis (57)
src\Compilers\Core\MSBuildTask\CommandLineBuilderExtension.cs (3)
104AppendSwitchIfNotNull(switchName, value.ToString(CultureInfo.InvariantCulture)); 153AppendSwitchIfNotNull(outerSwitchName, innerSwitchName + quotedParameter); 248AppendSwitchIfNotNull(switchName, parameter.ItemSpec);
src\Compilers\Core\MSBuildTask\Csc.cs (15)
207commandLine.AppendSwitchIfNotNull("/moduleassemblyname:", ModuleAssemblyName); 208commandLine.AppendSwitchIfNotNull("/pdb:", PdbFile); 210commandLine.AppendSwitchIfNotNull("/platform:", PlatformWith32BitPreference); 211commandLine.AppendSwitchIfNotNull("/errorreport:", ErrorReport); 213commandLine.AppendSwitchIfNotNull("/doc:", DocumentationFile); 214commandLine.AppendSwitchIfNotNull("/baseaddress:", BaseAddress); 216commandLine.AppendSwitchIfNotNull("/win32res:", Win32Resource); 217commandLine.AppendSwitchIfNotNull("/main:", MainEntryPoint); 218commandLine.AppendSwitchIfNotNull("/appconfig:", ApplicationConfiguration); 220commandLine.AppendSwitchIfNotNull("/preferreduilang:", PreferredUILang); 222commandLine.AppendSwitchIfNotNull("/nullable:", Nullable); 239commandLine.AppendSwitchIfNotNull("/sqmsessionguid:", VsSessionGuid); 274commandLine.AppendSwitchIfNotNull("@", response.ItemSpec); 295commandLine.AppendSwitchIfNotNull("/features:", $"InterceptorsNamespaces={featureValue}"); 426commandLine.AppendSwitchIfNotNull(switchName, reference.ItemSpec);
src\Compilers\Core\MSBuildTask\InteractiveCompiler.cs (2)
212commandLine.AppendSwitchIfNotNull("@", response.ItemSpec); 230commandLine.AppendSwitchIfNotNull("@", scriptResponse.ItemSpec);
src\Compilers\Core\MSBuildTask\ManagedCompiler.cs (20)
881commandLine.AppendSwitchIfNotNull("/debug:", DebugType); 888commandLine.AppendSwitchIfNotNull("/generatedfilesout:", GeneratedFilesOutputPath); 889commandLine.AppendSwitchIfNotNull("/keycontainer:", KeyContainer); 890commandLine.AppendSwitchIfNotNull("/keyfile:", KeyFile); 896commandLine.AppendSwitchIfNotNull("/pathmap:", PathMap); 900commandLine.AppendSwitchIfNotNull("/ruleset:", CodeAnalysisRuleSet); 901commandLine.AppendSwitchIfNotNull("/errorlog:", ErrorLog); 902commandLine.AppendSwitchIfNotNull("/subsystemversion:", SubsystemVersion); 906commandLine.AppendSwitchIfNotNull("/target:", TargetType); 909commandLine.AppendSwitchIfNotNull("/win32icon:", Win32Icon); 910commandLine.AppendSwitchIfNotNull("/win32manifest:", Win32Manifest); 924commandLine.AppendSwitchIfNotNull("/runtimemetadataversion:", RuntimeMetadataVersion); 925commandLine.AppendSwitchIfNotNull("/checksumalgorithm:", ChecksumAlgorithm); 927commandLine.AppendSwitchIfNotNull("/sourcelink:", SourceLink); 928commandLine.AppendSwitchIfNotNull("/langversion:", LangVersion); 948commandLine.AppendSwitchIfNotNull("/features:", feature.Trim()); 966commandLine.AppendSwitchIfNotNull("/analyzer:", analyzer.ItemSpec); 979commandLine.AppendSwitchIfNotNull("/additionalfile:", additionalFile.ItemSpec); 998commandLine.AppendSwitchIfNotNull("/embed:", embeddedFile.ItemSpec); 1012commandLine.AppendSwitchIfNotNull("/analyzerconfig:", analyzerConfigFile.ItemSpec);
src\Compilers\Core\MSBuildTask\Vbc.cs (17)
387commandLine.AppendSwitchIfNotNull("/baseaddress:", this.GetBaseAddressInHex()); 395commandLine.AppendSwitchIfNotNull("/optioncompare:", this.OptionCompare); 429commandLine.AppendSwitchIfNotNull("/optionstrict:", this.OptionStrictType); 436commandLine.AppendSwitchIfNotNull("/errorreport:", this.ErrorReport); 437commandLine.AppendSwitchIfNotNull("/platform:", this.PlatformWith32BitPreference); 439commandLine.AppendSwitchIfNotNull("/rootnamespace:", this.RootNamespace); 440commandLine.AppendSwitchIfNotNull("/sdkpath:", this.SdkPath); 441commandLine.AppendSwitchIfNotNull("/moduleassemblyname:", this.ModuleAssemblyName); 443commandLine.AppendSwitchIfNotNull("/preferreduilang:", this.PreferredUILang); 448commandLine.AppendSwitchIfNotNull("/vbruntime:", this.VBRuntimePath); 467commandLine.AppendSwitchIfNotNull("/vbruntime:", vbRuntimeSwitch); 481commandLine.AppendSwitchIfNotNull("/", this.Verbosity); 490commandLine.AppendSwitchIfNotNull("/doc:", this.DocumentationFile); 495commandLine.AppendSwitchIfNotNull("/win32resource:", this.Win32Resource); 500commandLine.AppendSwitchIfNotNull("/main:", this.MainEntryPoint); 537commandLine.AppendSwitchIfNotNull("/sqmsessionguid:", this.VsSessionGuid); 549commandLine.AppendSwitchIfNotNull("@", response.ItemSpec);
Microsoft.Build.Tasks.CodeAnalysis.Sdk (57)
src\Compilers\Core\MSBuildTask\CommandLineBuilderExtension.cs (3)
104AppendSwitchIfNotNull(switchName, value.ToString(CultureInfo.InvariantCulture)); 153AppendSwitchIfNotNull(outerSwitchName, innerSwitchName + quotedParameter); 248AppendSwitchIfNotNull(switchName, parameter.ItemSpec);
src\Compilers\Core\MSBuildTask\Csc.cs (15)
207commandLine.AppendSwitchIfNotNull("/moduleassemblyname:", ModuleAssemblyName); 208commandLine.AppendSwitchIfNotNull("/pdb:", PdbFile); 210commandLine.AppendSwitchIfNotNull("/platform:", PlatformWith32BitPreference); 211commandLine.AppendSwitchIfNotNull("/errorreport:", ErrorReport); 213commandLine.AppendSwitchIfNotNull("/doc:", DocumentationFile); 214commandLine.AppendSwitchIfNotNull("/baseaddress:", BaseAddress); 216commandLine.AppendSwitchIfNotNull("/win32res:", Win32Resource); 217commandLine.AppendSwitchIfNotNull("/main:", MainEntryPoint); 218commandLine.AppendSwitchIfNotNull("/appconfig:", ApplicationConfiguration); 220commandLine.AppendSwitchIfNotNull("/preferreduilang:", PreferredUILang); 222commandLine.AppendSwitchIfNotNull("/nullable:", Nullable); 239commandLine.AppendSwitchIfNotNull("/sqmsessionguid:", VsSessionGuid); 274commandLine.AppendSwitchIfNotNull("@", response.ItemSpec); 295commandLine.AppendSwitchIfNotNull("/features:", $"InterceptorsNamespaces={featureValue}"); 426commandLine.AppendSwitchIfNotNull(switchName, reference.ItemSpec);
src\Compilers\Core\MSBuildTask\InteractiveCompiler.cs (2)
212commandLine.AppendSwitchIfNotNull("@", response.ItemSpec); 230commandLine.AppendSwitchIfNotNull("@", scriptResponse.ItemSpec);
src\Compilers\Core\MSBuildTask\ManagedCompiler.cs (20)
881commandLine.AppendSwitchIfNotNull("/debug:", DebugType); 888commandLine.AppendSwitchIfNotNull("/generatedfilesout:", GeneratedFilesOutputPath); 889commandLine.AppendSwitchIfNotNull("/keycontainer:", KeyContainer); 890commandLine.AppendSwitchIfNotNull("/keyfile:", KeyFile); 896commandLine.AppendSwitchIfNotNull("/pathmap:", PathMap); 900commandLine.AppendSwitchIfNotNull("/ruleset:", CodeAnalysisRuleSet); 901commandLine.AppendSwitchIfNotNull("/errorlog:", ErrorLog); 902commandLine.AppendSwitchIfNotNull("/subsystemversion:", SubsystemVersion); 906commandLine.AppendSwitchIfNotNull("/target:", TargetType); 909commandLine.AppendSwitchIfNotNull("/win32icon:", Win32Icon); 910commandLine.AppendSwitchIfNotNull("/win32manifest:", Win32Manifest); 924commandLine.AppendSwitchIfNotNull("/runtimemetadataversion:", RuntimeMetadataVersion); 925commandLine.AppendSwitchIfNotNull("/checksumalgorithm:", ChecksumAlgorithm); 927commandLine.AppendSwitchIfNotNull("/sourcelink:", SourceLink); 928commandLine.AppendSwitchIfNotNull("/langversion:", LangVersion); 948commandLine.AppendSwitchIfNotNull("/features:", feature.Trim()); 966commandLine.AppendSwitchIfNotNull("/analyzer:", analyzer.ItemSpec); 979commandLine.AppendSwitchIfNotNull("/additionalfile:", additionalFile.ItemSpec); 998commandLine.AppendSwitchIfNotNull("/embed:", embeddedFile.ItemSpec); 1012commandLine.AppendSwitchIfNotNull("/analyzerconfig:", analyzerConfigFile.ItemSpec);
src\Compilers\Core\MSBuildTask\Vbc.cs (17)
387commandLine.AppendSwitchIfNotNull("/baseaddress:", this.GetBaseAddressInHex()); 395commandLine.AppendSwitchIfNotNull("/optioncompare:", this.OptionCompare); 429commandLine.AppendSwitchIfNotNull("/optionstrict:", this.OptionStrictType); 436commandLine.AppendSwitchIfNotNull("/errorreport:", this.ErrorReport); 437commandLine.AppendSwitchIfNotNull("/platform:", this.PlatformWith32BitPreference); 439commandLine.AppendSwitchIfNotNull("/rootnamespace:", this.RootNamespace); 440commandLine.AppendSwitchIfNotNull("/sdkpath:", this.SdkPath); 441commandLine.AppendSwitchIfNotNull("/moduleassemblyname:", this.ModuleAssemblyName); 443commandLine.AppendSwitchIfNotNull("/preferreduilang:", this.PreferredUILang); 448commandLine.AppendSwitchIfNotNull("/vbruntime:", this.VBRuntimePath); 467commandLine.AppendSwitchIfNotNull("/vbruntime:", vbRuntimeSwitch); 481commandLine.AppendSwitchIfNotNull("/", this.Verbosity); 490commandLine.AppendSwitchIfNotNull("/doc:", this.DocumentationFile); 495commandLine.AppendSwitchIfNotNull("/win32resource:", this.Win32Resource); 500commandLine.AppendSwitchIfNotNull("/main:", this.MainEntryPoint); 537commandLine.AppendSwitchIfNotNull("/sqmsessionguid:", this.VsSessionGuid); 549commandLine.AppendSwitchIfNotNull("@", response.ItemSpec);
Microsoft.Build.Tasks.Core (57)
Al.cs (25)
332commandLine.AppendSwitchIfNotNull("/algid:", AlgorithmId); 333commandLine.AppendSwitchIfNotNull("/baseaddress:", BaseAddress); 334commandLine.AppendSwitchIfNotNull("/company:", CompanyName); 335commandLine.AppendSwitchIfNotNull("/configuration:", Configuration); 336commandLine.AppendSwitchIfNotNull("/copyright:", Copyright); 337commandLine.AppendSwitchIfNotNull("/culture:", Culture); 339commandLine.AppendSwitchIfNotNull("/description:", Description); 340commandLine.AppendSwitchIfNotNull("/evidence:", EvidenceFile); 341commandLine.AppendSwitchIfNotNull("/fileversion:", FileVersion); 342commandLine.AppendSwitchIfNotNull("/flags:", Flags); 344commandLine.AppendSwitchIfNotNull("/keyfile:", KeyFile); 345commandLine.AppendSwitchIfNotNull("/keyname:", KeyContainer); 346commandLine.AppendSwitchIfNotNull("/main:", MainEntryPoint); 347commandLine.AppendSwitchIfNotNull("/out:", OutputAssembly?.ItemSpec); 348commandLine.AppendSwitchIfNotNull("/platform:", PlatformWith32BitPreference); 349commandLine.AppendSwitchIfNotNull("/product:", ProductName); 350commandLine.AppendSwitchIfNotNull("/productversion:", ProductVersion); 351commandLine.AppendSwitchIfNotNull("/target:", TargetType); 352commandLine.AppendSwitchIfNotNull("/template:", TemplateFile); 353commandLine.AppendSwitchIfNotNull("/title:", Title); 354commandLine.AppendSwitchIfNotNull("/trademark:", Trademark); 355commandLine.AppendSwitchIfNotNull("/version:", Version); 356commandLine.AppendSwitchIfNotNull("/win32icon:", Win32Icon); 357commandLine.AppendSwitchIfNotNull("/win32res:", Win32Resource); 378commandLine.AppendSwitchIfNotNull("@", responseFile);
AspNetCompiler.cs (6)
249commandLine.AppendSwitchIfNotNull("-m ", MetabasePath); 250commandLine.AppendSwitchIfNotNull("-v ", VirtualPath); 251commandLine.AppendSwitchIfNotNull("-p ", PhysicalPath); 278commandLine.AppendSwitchIfNotNull("", TargetPath); 290commandLine.AppendSwitchIfNotNull("-keyfile ", KeyFile); 291commandLine.AppendSwitchIfNotNull("-keycontainer ", KeyContainer);
AxImp.cs (2)
132commandLine.AppendSwitchIfNotNull("/out:", OutputAssembly); 133commandLine.AppendSwitchIfNotNull("/rcw:", RuntimeCallableWrapperAssembly);
AxTlbBaseTask.cs (3)
160commandLine.AppendSwitchIfNotNull("/publickey:", KeyFile); 164commandLine.AppendSwitchIfNotNull("/keyfile:", KeyFile); 167commandLine.AppendSwitchIfNotNull("/keycontainer:", KeyContainer);
CommandLineBuilderExtension.cs (3)
121AppendSwitchIfNotNull(switchName, value.ToString(CultureInfo.InvariantCulture)); 145AppendSwitchIfNotNull(outerSwitchName, innerSwitchName + quotedParameter); 245AppendSwitchIfNotNull(switchName, parameter.ItemSpec);
LC.cs (4)
146commandLine.AppendSwitchIfNotNull("/target:", LicenseTarget.ItemSpec); 150commandLine.AppendSwitchIfNotNull("/complist:", item.ItemSpec); 153commandLine.AppendSwitchIfNotNull("/outdir:", OutputDirectory); 159commandLine.AppendSwitchIfNotNull("/i:", item.ItemSpec);
RoslynCodeTaskFactory\RoslynCodeTaskFactoryCompilers.cs (3)
106commandLine.AppendSwitchIfNotNull(ReferenceSwitch, reference.ItemSpec); 113commandLine.AppendSwitchIfNotNull("/target:", TargetType); 164commandLine.AppendSwitchIfNotNull("/rootnamespace:", RootNamespace);
SGen.cs (3)
372commandLineBuilder.AppendSwitchIfNotNull("/assembly:", AssemblyFullPath); 388commandLineBuilder.AppendSwitchIfNotNull("/reference:", string.Join(",", References)); 397commandLineBuilder.AppendSwitchIfNotNull("/type:", type);
TlbImp.cs (6)
242commandLine.AppendSwitchIfNotNull("/asmversion:", AssemblyVersion?.ToString()); 243commandLine.AppendSwitchIfNotNull("/namespace:", AssemblyNamespace); 244commandLine.AppendSwitchIfNotNull("/machine:", Machine); 247commandLine.AppendSwitchIfNotNull("/out:", OutputAssembly); 250commandLine.AppendSwitchIfNotNull("/transform:", ConvertTransformFlagsToCommandLineCommand(Transform)); 256commandLine.AppendSwitchIfNotNull("/reference:", referenceFile);
XamlTaskFactory\CommandLineGenerator.cs (2)
354clb.AppendSwitchIfNotNull(commandLineToolSwitch.SwitchValue, itemName.ItemSpec); 403clb.AppendSwitchIfNotNull(commandLineToolSwitch.SwitchValue, fileName);
Microsoft.Build.Tasks.UnitTests (2)
ToolTaskExtension_Tests.cs (2)
108commandLineBuilder.AppendSwitchIfNotNull("/A:", "D66B977148114482A88B0EFC1E531F02"); 109commandLineBuilder.AppendSwitchIfNotNull("/B:", "F9E03765A87543F4B385664B8DB7619D");
Microsoft.Build.Utilities.Core (5)
CommandLineBuilder.cs (1)
556AppendSwitchIfNotNull(switchName, parameter.ItemSpec);
TrackedDependencies\FileTracker.cs (4)
612builder.AppendSwitchIfNotNull("/d ", dllName); 622builder.AppendSwitchIfNotNull("/i ", intermediateDirectory); 625builder.AppendSwitchIfNotNull("/r ", rootFiles); 627builder.AppendSwitchIfNotNull("/b ", cancelEventName); // b for break
Microsoft.Build.Utilities.UnitTests (14)
CommandLineBuilder_Tests.cs (14)
42c.AppendSwitchIfNotNull("/animal:", "dog"); 55c.AppendSwitchIfNotNull("/animal:", "dog and pony"); 68c.AppendSwitchIfNotNull("/i:", "iI"); 300c.AppendSwitchIfNotNull("/D", "LSYSTEM_COMPATIBLE_ASSEMBLY_NAME=L\"Microsoft.Windows.SystemCompatible\""); 311c.AppendSwitchIfNotNull("/D", @"ASSEMBLY_KEY_FILE=""c:\\foo\\FinalKeyFile.snk"""); 322c.AppendSwitchIfNotNull("/D", @"""A B"" and ""C"""); 333c.AppendSwitchIfNotNull("/D", @"A \B"); 344c.AppendSwitchIfNotNull("/D", @"A"" \""B"); 367c.AppendSwitchIfNotNull("/D", @"A B\"); 378c.AppendSwitchIfNotNull("/D", @"AB\"); 389c.AppendSwitchIfNotNull("/D", @"foo-bar"); 400c.AppendSwitchIfNotNull("/D", @"foo-bar"); 436c.AppendSwitchIfNotNull("/D", @"A='""'"); // /DA='"' 445c.AppendSwitchIfNotNull("/foo:", "bar");
Microsoft.DotNet.Build.Tasks.Workloads (9)
Wix\CommandLineBuilderExtensions.cs (1)
25builder.AppendSwitchIfNotNull(switchName, value);
Wix\CompilerToolTask.cs (2)
74CommandLineBuilder.AppendSwitchIfNotNull("-out ", OutputPath); 78CommandLineBuilder.AppendSwitchIfNotNull("-arch ", Architecture);
Wix\HarvesterToolTask.cs (4)
110CommandLineBuilder.AppendSwitchIfNotNull("dir ", SourceDirectory); 112CommandLineBuilder.AppendSwitchIfNotNull("-cg ", ComponentGroupName); 136CommandLineBuilder.AppendSwitchIfNotNull("-dr ", DirectoryReference); 137CommandLineBuilder.AppendSwitchIfNotNull("-o ", OutputFile);
Wix\LinkerToolTask.cs (2)
76CommandLineBuilder.AppendSwitchIfNotNull("-o ", OutputFile); 79CommandLineBuilder.AppendSwitchIfNotNull("-sice:", SuppressIces);