C# Класс XSharp.Build.Xsc

Наследование: Microsoft.Build.Tasks.ManagedCompiler
Показать файл Открыть проект

Private Properties

Свойство Тип Описание
AddAdditionalFilesToCommandLine void
AddAnalyzersToCommandLine void
AddCscCompilerCommands void
AddFeatures void
AddManagedCompilerCommands void
AddReferencesToCommandLine void
AddVOCompatibilityCommands void
ConfigureDebugProperties void
FindXsc string

Открытые методы

Метод Описание
Xsc ( ) : System

Защищенные методы

Метод Описание
AddResponseFileCommands ( Microsoft.Build.Tasks.CommandLineBuilderExtension commandLine ) : void
AddResponseFileCommandsImpl ( Microsoft.Build.Tasks.CommandLineBuilderExtension cmdline ) : void
ExecuteTool ( string pathToTool, string responseFileCommands, string commandLineCommands ) : int
GenerateCommandLineCommands ( ) : string
GenerateFullPathToTool ( ) : string
GenerateResponseFileCommands ( ) : string
LogEventsFromTextOutput ( string singleLine, MessageImportance messageImportance ) : void

Приватные методы

Метод Описание
AddAdditionalFilesToCommandLine ( XSharpCommandLineBuilder commandLine ) : void

Adds a "/additionalfile:" switch to the command line for each additional file.

AddAnalyzersToCommandLine ( XSharpCommandLineBuilder commandLine, ITaskItem analyzers ) : void

Adds a "/analyzer:" switch to the command line for each provided analyzer.

AddCscCompilerCommands ( XSharpCommandLineBuilder commandLine ) : void

Mostly copied from the csc task in Roslyn

AddFeatures ( XSharpCommandLineBuilder commandLine, string features ) : void

Adds a "/features:" switch to the command line for each provided feature.

AddManagedCompilerCommands ( XSharpCommandLineBuilder cmdline ) : void

Mostly copied from the ManagedCompiler task in Roslyn

AddReferencesToCommandLine ( XSharpCommandLineBuilder commandLine, ITaskItem references, bool isInteractive = false ) : void

The C# compiler (starting with Whidbey) supports assembly aliasing for references. See spec at http://devdiv/spectool/Documents/Whidbey/VCSharp/Design%20Time/M3%20DCRs/DCR%20Assembly%20aliases.doc. This method handles the necessary work of looking at the "Aliases" attribute on the incoming "References" items, and making sure to generate the correct command-line on csc.exe. The syntax for aliasing a reference is: csc.exe /reference:Foo=System.Xml.dll The "Aliases" attribute on the "References" items is actually a comma-separated list of aliases, and if any of the aliases specified is the string "global", then we add that reference to the command-line without an alias.

AddVOCompatibilityCommands ( XSharpCommandLineBuilder commandline ) : void
ConfigureDebugProperties ( ) : void

Configure the debug switches which will be placed on the compiler command-line. The matrix of debug type and symbol inputs and the desired results is as follows: Debug Symbols DebugType Desired Results True Full /debug+ /debug:full True PdbOnly /debug+ /debug:PdbOnly True None /debug- True Blank /debug+ False Full /debug- /debug:full False PdbOnly /debug- /debug:PdbOnly False None /debug- False Blank /debug- Blank Full /debug:full Blank PdbOnly /debug:PdbOnly Blank None /debug- Debug: Blank Blank /debug+ //Microsoft.common.targets will set this Release: Blank Blank "Nothing for either switch" The logic is as follows: If debugtype is none set debugtype to empty and debugSymbols to false If debugType is blank use the debugsymbols "as is" If debug type is set, use its value and the debugsymbols value "as is"

FindXsc ( string toolName ) : string

Описание методов

AddResponseFileCommands() защищенный Метод

protected AddResponseFileCommands ( Microsoft.Build.Tasks.CommandLineBuilderExtension commandLine ) : void
commandLine Microsoft.Build.Tasks.CommandLineBuilderExtension
Результат void

AddResponseFileCommandsImpl() защищенный Метод

protected AddResponseFileCommandsImpl ( Microsoft.Build.Tasks.CommandLineBuilderExtension cmdline ) : void
cmdline Microsoft.Build.Tasks.CommandLineBuilderExtension
Результат void

ExecuteTool() защищенный Метод

protected ExecuteTool ( string pathToTool, string responseFileCommands, string commandLineCommands ) : int
pathToTool string
responseFileCommands string
commandLineCommands string
Результат int

GenerateCommandLineCommands() защищенный Метод

protected GenerateCommandLineCommands ( ) : string
Результат string

GenerateFullPathToTool() защищенный Метод

protected GenerateFullPathToTool ( ) : string
Результат string

GenerateResponseFileCommands() защищенный Метод

protected GenerateResponseFileCommands ( ) : string
Результат string

LogEventsFromTextOutput() защищенный Метод

protected LogEventsFromTextOutput ( string singleLine, MessageImportance messageImportance ) : void
singleLine string
messageImportance MessageImportance
Результат void

Xsc() публичный Метод

public Xsc ( ) : System
Результат System