Summary
    Compiles C# programs.
    
		- Assembly
 - NAnt
.DotNet .dll  - Namespace
 - NAnt
.DotNet .Tasks  - Interfaces
 - Base Types
 
							graph BT
	Type-->Base0["CompilerBase"]
	click Base0 "/api/NAnt.DotNet.Tasks/CompilerBase"
	Base0-->Base1["ExternalProgramBase"]
	click Base1 "/api/NAnt.Core.Tasks/ExternalProgramBase"
	Base1-->Base2["Task"]
	click Base2 "/api/NAnt.Core/Task"
	Base2-->Base3["Element"]
	click Base3 "/api/NAnt.Core/Element"
	Base3-->Base4["Object"]
	Type-.->Interface0["IConditional"]
	click Interface0 "/api/NAnt.Core/IConditional"
	Type["CscTask"]
class Type type-node
						
					Syntax
[TaskName("csc")]
[ProgramLocation(LocationType.FrameworkDir)]
public class CscTask : CompilerBase, IConditional
		Examples
Compile a "HelloWorld" application, including embedded resources.
    <csc target="exe" output="HelloWorld.exe" debug="true">
    <nowarn>
        <!-- do not report warnings for missing XML comments -->
        <warning number="0519" />
    </nowarn>
    <sources>
        <include name="**/*.cs" />
    </sources>
    <resources dynamicprefix="true" prefix="HelloWorld">
        <include name="**/*.resx" />
    </resources>
    <references>
        <include name="System.dll" />
        <include name="System.Data.dll" />
    </references>
</csc>
    Remarks
    In order to have 
    NAnt.DotNet.Tasks.CscTask generate manifest resource names
    that match those generated by Microsoft Visual Studio.NET, the value of
    the NAnt.DotNet.Types.ResourceFileSet.Prefix attribute of the <NAnt.DotNet.Tasks.CompilerBase.ResourcesList>
    element should match the "Default Namespace" of the C# project, and the 
    value of the NAnt.DotNet.Types.ResourceFileSet.DynamicPrefix attribute 
    should be set to "true".
    Attributes
| Type | Description | 
|---|---|
| TaskNameAttribute | Indicates that class should be treated as a task. | 
| Program | 
						Indicates the location that a task executable can be located in. | 
Fields
| Name | Constant Value | Summary | 
|---|---|---|
| CodebehindExtensions | 
									 
    Contains a list of extensions for all file types that should be treated as
    'code-behind' when looking for resources.  Ultimately this will determine
    if we use the "namespace+filename" or "namespace+classname" algorithm, since
    code-behind will use the "namespace+classname" algorithm.
     
											Inherited from CompilerBase 
											static 
								 | 
							|
| CultureNames | 
									 
    Case-insensitive list of valid culture names for this platform.
     
											Inherited from CompilerBase 
											static 
								 | 
							|
| UnknownExitCode | -1000 | 
									 
    Defines the exit code that will be returned by  
											NAnt.Core.Tasks.ExternalProgramBase.ExitCode
    if the process could not be started, or did not exit (in time).
    Inherited from ExternalProgramBase 
											static 
								 | 
							
Properties
| Name | Value | Summary | 
|---|---|---|
| Arguments | ArgumentCollection | 
									 
    The command-line arguments for the external program.
     
											Inherited from ExternalProgramBase 
								 | 
							
| BaseAddress | string | 
									 
    The preferred base address at which to load a DLL. The default base 
    address for a DLL is set by the .NET Framework common language 
    runtime.
     
								 | 
							
| BaseDirectory | DirectoryInfo | 
									 
    Gets the working directory for the application.
     
											Inherited from ExternalProgramBase 
								 | 
							
| Checked | bool | 
									 
    Specifies whether an integer arithmetic statement that is not in 
    the scope of the  
								checked or unchecked keywords and 
    that results in a value outside the range of the data type should 
    cause a run-time exception. The default is false.
     | 
							
| ClassNameRegex | Regex | 
									 
    Gets the class name regular expression for the language of the 
    current compiler.
     
								 | 
							
| Codepage | string | 
									 
    Specifies the code page to use for all source code files in the 
    compilation.
     
								 | 
							
| CommandLine | string | 
									 
    Gets the command-line arguments, separated by spaces.
     
											Inherited from ExternalProgramBase 
								 | 
							
| CustomXmlProcessing | bool | 
									 
    Gets a value indicating whether the element is performing additional
    processing using the  
											NAnt.Core.Element.XmlNode that was used to 
    initialize the element.
    Inherited from Element 
								 | 
							
| Debug | bool | 
									 
    No longer expose this to build authors. Use  
								NAnt.DotNet.Tasks.CscTask.DebugOutput
    instead.
     | 
							
| DebugOutput | DebugOutput | 
									 
    Specifies the type of debugging information generated by the 
    compiler. The default is  
								NAnt.DotNet.Types.DebugOutput.None.
     | 
							
| Define | string | 
									 
    Define conditional compilation symbol(s).
     
											Inherited from CompilerBase 
								 | 
							
| DelaySign | DelaySign | 
									 
    Specifies whether to delay sign the assembly using only the public
    portion of the strong name key. The default is 
     
											NAnt.DotNet.Types.DelaySign.NotSet.
    Inherited from CompilerBase 
								 | 
							
| DocFile | FileInfo | 
									 
    The name of the XML documentation file to generate.
     
								 | 
							
| ErrorWriter | TextWriter | 
									 
    Gets or sets the  
											System.IO.TextWriter to which error output
    of the external program will be written.
    Inherited from ExternalProgramBase 
								 | 
							
| ExeName | string | 
									 
    The name of the executable that should be used to launch the 
    external program.
     
											Inherited from ExternalProgramBase 
								 | 
							
| ExitCode | int | 
									 
    Gets the value that the process specified when it terminated.
     
											Inherited from ExternalProgramBase 
								 | 
							
| Extension | string | 
									 
    Gets the file extension required by the current compiler.
     
								 | 
							
| FailOnError | bool | 
									 
    Determines if task failure stops the build, or is just reported. 
    The default is  
											true.
    Inherited from Task 
								 | 
							
| FileAlign | int | 
									 
    Specifies the size of sections in the output file. Valid values are
    512, 1024, 2048, 4096, and 8192.
     
								 | 
							
| ForceRebuild | bool | 
									 
    Instructs NAnt to recompile the output file regardless of the file timestamps.
     
											Inherited from CompilerBase 
								 | 
							
| IfDefined | bool | 
									 
    If  
											true then the task will be executed; otherwise, 
    skipped. The default is true.
    Inherited from Task 
								 | 
							
| KeyContainer | string | 
									 
    Specifies the key pair container used to strongname the assembly.
     
											Inherited from CompilerBase 
								 | 
							
| KeyFile | FileInfo | 
									 
    Specifies a strong name key file.
     
											Inherited from CompilerBase 
								 | 
							
| LangVersion | string | 
									 
    Causes the compiler to only accept syntax that is included in a
    given specification.
     
								 | 
							
| Lib | FileSet | 
									 
    Additional directories to search in for assembly references.
     
											Inherited from CompilerBase 
								 | 
							
| Location | Location | 
									 
    Gets or sets the location in the build file where the element is 
    defined.
     
											Inherited from Element 
								 | 
							
| LogPrefix | string | 
									 
    The prefix used when sending messages to the log.
     
											Inherited from Task 
								 | 
							
| MainType | string | 
									 
    Specifies which type contains the Main method that you want to use
    as the entry point into the program.
     
											Inherited from CompilerBase 
								 | 
							
| Managed | ManagedExecution | 
									 
    Specifies whether the external program should be treated as a managed
    application, possibly forcing it to be executed under the currently
    targeted version of the CLR.
     
											Inherited from ExternalProgramBase 
								 | 
							
| McsSdk | double | 
									 
    Gets or sets the mcs sdk version to apply to the new mcs compiler
    for Mono 3.0+
     
								 | 
							
| Modules | AssemblyFileSet | 
									 
    Link the specified modules into this assembly.
     
											Inherited from CompilerBase 
								 | 
							
| Name | string | 
									 
    The name of the task.
     
											Inherited from Task 
								 | 
							
| NamespaceManager | XmlNamespaceManager | 
									 
    Gets or sets the  
											System.Xml.XmlNamespaceManager.
    Inherited from Element 
								 | 
							
| NamespaceRegex | Regex | 
									 
    Gets the namespace regular expression for the language of the current compiler.
     
								 | 
							
| NoConfig | bool | 
									 
    Instructs the compiler not to use implicit references to assemblies.
    The default is  
								false.
     | 
							
| NoStdLib | bool | 
									 
    Instructs the compiler not to import mscorlib.dll. The default is 
     
								false.
     | 
							
| NoWarn | string | 
									 
    Specifies a comma-separated list of warnings that should be suppressed
    by the compiler.
     
											Inherited from CompilerBase 
								 | 
							
| Optimize | bool | 
									 
    Specifies whether the compiler should perform optimizations to the 
    make output files smaller, faster, and more efficient. The default 
    is  
								false.
     | 
							
| Output | FileInfo | 
									 
    Gets the file to which the standard output should be redirected.
     
											Inherited from ExternalProgramBase 
								 | 
							
| OutputAppend | bool | 
									 
    Gets a value indicating whether output will be appended to the 
     
											NAnt.Core.Tasks.ExternalProgramBase.Output.
    Inherited from ExternalProgramBase 
								 | 
							
| OutputFile | FileInfo | 
									 
    The output file created by the compiler.
     
											Inherited from CompilerBase 
								 | 
							
| OutputTarget | string | 
									 
    Output type. Possible values are  
											exe, winexe,
    library or module.
    Inherited from CompilerBase 
								 | 
							
| OutputWriter | TextWriter | 
									 
    Gets or sets the  
											System.IO.TextWriter to which standard output
    messages of the external program will be written.
    Inherited from ExternalProgramBase 
								 | 
							
| Packages | PackageCollection | 
									 
    Specifies list of packages to reference.
     
											Inherited from CompilerBase 
								 | 
							
| Parent | Object | 
									 
    Gets or sets the parent of the element.
     
											Inherited from Element 
								 | 
							
| Platform | string | 
									 
    Specifies which platform version of common language runtime (CLR)
    can run the output file.
     
								 | 
							
| ProcessId | int | 
									 
    Gets the unique identifier for the spawned application.
     
											Inherited from ExternalProgramBase 
								 | 
							
| ProgramArguments | string | 
									 
    Gets the command-line arguments for the external program.
     
											Inherited from CompilerBase 
								 | 
							
| ProgramFileName | string | 
									 
    Gets the filename of the external program to start.
     
											Inherited from ExternalProgramBase 
								 | 
							
| Project | Project | 
									 
    Gets or sets the  
											NAnt.Core.Element.Project to which this element belongs.
    Inherited from Element 
								 | 
							
| Properties | PropertyDictionary | 
									 
    Gets the properties local to this  
											NAnt.Core.Element and the 
    NAnt.Core.Element.Project.
    Inherited from Element 
								 | 
							
| References | AssemblyFileSet | 
									 
    Reference metadata from the specified assembly files.
     
											Inherited from CompilerBase 
								 | 
							
| ResourcesList | Resource | 
								
									 
    Resources to embed.
     
											Inherited from CompilerBase 
								 | 
							
| Sources | FileSet | 
									 
    The set of source files for compilation.
     
											Inherited from CompilerBase 
								 | 
							
| Spawn | bool | 
									 
    Gets or sets a value indicating whether the application should be
    spawned. If you spawn an application, its output will not be logged
    by NAnt. The default is  
											false.
    Inherited from ExternalProgramBase 
								 | 
							
| SupportsDelaySign | bool | 
									 
    Indicates whether the compiler for a given target framework supports
    the "delaysign" option. The default is  
											false.
    Inherited from CompilerBase 
								 | 
							
| Supports | 
								bool | 
									 
    Specifies whether the compiler for the active target framework
    supports generation of XML Documentation file. The default is 
     
								true.
     | 
							
| SupportsKeyContainer | bool | 
									 
    Indicates whether the compiler for a given target framework supports
    the "keycontainer" option. The default is  
											false.
    Inherited from CompilerBase 
								 | 
							
| SupportsKeyFile | bool | 
									 
    Indicates whether the compiler for a given target framework supports
    the "keyfile" option. The default is  
											false.
    Inherited from CompilerBase 
								 | 
							
| SupportsLangVersion | bool | 
									 
    Specifies whether the compiler for the active target framework
    supports accepting only a specific language syntax.
    The default is  
								false.
     | 
							
| SupportsNoWarnList | bool | 
									 
    Indicates whether the compiler for a given target framework supports
    a command line option that allows a list of warnings to be
    suppressed. The default is  
											false.
    Inherited from CompilerBase 
								 | 
							
| Supports | 
								bool | 
									 
    Indicates whether package references are supported by compiler for 
    a given target framework. The default is  
											false.
    Inherited from CompilerBase 
								 | 
							
| SupportsPlatform | bool | 
									 
    Specifies whether the compiler for the active target framework
    supports limiting the platform on which the compiled code can run.
    The default is  
								false.
     | 
							
| Supports | 
								bool | 
									 
    Indicates whether the compiler for a given target framework supports
    the "warnaserror" option that takes a list of warnings. The default 
    is  
											false.
    Inherited from CompilerBase 
								 | 
							
| SuppressWarnings | Compiler | 
								
									 
    Specifies a list of warnings that you want the compiler to suppress.
     
											Inherited from CompilerBase 
								 | 
							
| Threshold | Level | 
									 
    Gets or sets the log threshold for this  
											NAnt.Core.Task. By
    default the threshold of a task is NAnt.Core.Level.Debug,
    causing no messages to be filtered in the task itself.
    Inherited from Task 
								 | 
							
| TimeOut | int | 
									 
    The maximum amount of time the application is allowed to execute, 
    expressed in milliseconds.  Defaults to no time-out.
     
											Inherited from ExternalProgramBase 
								 | 
							
| UnlessDefined | bool | 
									 
    Opposite of  
											NAnt.Core.Task.IfDefined. If false 
    then the task will be executed; otherwise, skipped. The default is 
    false.
    Inherited from Task 
								 | 
							
| Unsafe | bool | 
									 
    Instructs the compiler to allow code that uses the  
								unsafe 
    keyword. The default is false.
     | 
							
| UseRuntimeEngine | bool | 
									 
    Specifies whether the external program is a managed application
    which should be executed using a runtime engine, if configured. 
    The default is  
											false.
    Inherited from ExternalProgramBase 
								 | 
							
| Verbose | bool | 
									 
    Determines whether the task should report detailed build log messages. 
    The default is  
											false.
    Inherited from Task 
								 | 
							
| WarnAsError | bool | 
									 
    Instructs the compiler to treat all warnings as errors. The default
    is  
											false.
    Inherited from CompilerBase 
								 | 
							
| WarningAsError | WarningAsError | 
									 
    Controls which warnings should be reported as errors.
     
											Inherited from CompilerBase 
								 | 
							
| WarningLevel | string | 
									 
    Specifies the warning level for the compiler to display. Valid values 
    are  
								0-4. The default is 4.
     | 
							
| Win32Icon | FileInfo | 
									 
    Icon to associate with the application.
     
											Inherited from CompilerBase 
								 | 
							
| Win32Res | FileInfo | 
									 
    Specifies a Win32 resource file (.res).
     
											Inherited from CompilerBase 
								 | 
							
| XmlNode | XmlNode | 
									 
    Gets or sets the XML node of the element.
     
											Inherited from Element 
								 | 
							
Methods
| Name | Value | Summary | 
|---|---|---|
| CompileResxResources | 
								void | 
									 
    Compiles a set of resx files to a .resources files.
     
											Inherited from CompilerBase 
								 | 
							
| CopyTo | 
								void | 
									 
    Copies all instance data of the  
											NAnt.Core.Element to a given
    NAnt.Core.Element.
    Inherited from Element 
								 | 
							
| Execute | 
								void | 
									 
    Executes the task unless it is skipped.
     
											Inherited from Task 
								 | 
							
| ExecuteTask | 
								void | 
									 
    Compiles the sources and resources.
     
											Inherited from CompilerBase 
								 | 
							
| Get | 
								XmlNode | 
									 
    Locates the XML node for the specified attribute in either the
    configuration section of the extension assembly or the.project.
     
											Inherited from Task 
								 | 
							
| Get | 
								XmlNode | 
									
											 Inherited from Element 
								 | 
							
| GetLocation | 
								Location | 
									 
    Retrieves the location in the build file where the element is 
    defined.
     
											Inherited from Element 
								 | 
							
| Get | 
								string | 
									 
    Determines the manifest resource name of the given resource file.
     
											Inherited from CompilerBase 
								 | 
							
| Get | 
								string | 
									 
    Determines the manifest resource name of the given resource file.
     
											Inherited from CompilerBase 
								 | 
							
| GetResourceCulture | 
								CultureInfo | 
									 
    Determines the culture associated with a given resource file by
    scanning the filename for valid culture names.
     
											Inherited from CompilerBase 
											static 
								 | 
							
| GetResourceLinkage | 
								CompilerBase | 
								
									 
    Finds the correct namespace/classname for a resource file from the 
    given dependent source file.
     
											Inherited from CompilerBase 
								 | 
							
| Initialize | 
								void | 
									 Initializes the task. 
											Inherited from Task 
								 | 
							
| Initialize | 
								void | 
									 
    Performs default initialization.
     
											Inherited from Element 
								 | 
							
| Initialize | 
								Element | 
									 
    Initializes the build element.
     
											Inherited from Element 
											static 
								 | 
							
| InitializeElement | 
								void | 
									 
    Derived classes should override to this method to provide extra 
    initialization and validation not covered by the base class.
     
											Inherited from Element 
								 | 
							
| InitializeTask | 
								void | 
									 Initializes the task. 
											Inherited from Task 
								 | 
							
| Initialize | 
								void | 
									 
    Initializes the configuration of the task using configuration 
    settings retrieved from the NAnt configuration file.
     
											Inherited from Task 
								 | 
							
| InitializeXml | 
								void | 
									 
    Initializes all build attributes and child elements.
     
											Inherited from Element 
								 | 
							
| IsLogEnabledFor | 
								bool | 
									 
    Determines whether build output is enabled for the given 
     
											NAnt.Core.Level.
    Inherited from Task 
								 | 
							
| LinkResourceAssembly | 
								void | 
									 
    Link a list of files into a resource assembly.
     
											Inherited from CompilerBase 
								 | 
							
| Log | 
								void | 
									 
    Logs a message with the given priority.
     
											Inherited from Task 
								 | 
							
| Log | 
								void | 
									 
    Logs a formatted message with the given priority.
     
											Inherited from Task 
								 | 
							
| NeedsCompiling | 
								bool | 
									 
    Determines whether compilation is needed.
     
								 | 
							
| Perform | 
								CompilerBase | 
								
									 
    Extracts the associated namespace/classname linkage found in the 
    given stream.
     
											Inherited from CompilerBase 
								 | 
							
| PrepareProcess | 
								void | 
									 
    Updates the  
											System.Diagnostics.ProcessStartInfo of the specified 
    System.Diagnostics.Process.
    Inherited from ExternalProgramBase 
								 | 
							
| StartProcess | 
								Process | 
									 
    Starts the process and handles errors.
     
											Inherited from ExternalProgramBase 
								 | 
							
| Write | 
								void | 
									 
    Writes conditional compilation constants to the specified
     
											System.IO.TextWriter.
    Inherited from CompilerBase 
								 | 
							
| Write | 
								void | 
									 
    Writes module references to the specified  
											System.IO.TextWriter.
    Inherited from CompilerBase 
								 | 
							
| WriteNoWarnList | 
								void | 
									 
    Writes list of warnings to suppress to the specified 
     
											System.IO.TextWriter.
    Inherited from CompilerBase 
								 | 
							
| WriteOption | 
								void | 
									 
    Writes an option using the default output format.
     
											Inherited from CompilerBase 
								 | 
							
| WriteOption | 
								void | 
									 
    Writes an option and its value using the default output format.
     
											Inherited from CompilerBase 
								 | 
							
| WriteOptions | 
								void | 
									 
    Writes the compiler options to the specified  
								System.IO.TextWriter.
     | 
							
| Write | 
								void | 
									 
    Writes package references to the specified  
											System.IO.TextWriter.
    Inherited from CompilerBase 
								 | 
							
| WriteWarningsAsError | 
								void | 
									 
    Writes list of warnings to (not) treat as errors to the specified 
     
											System.IO.TextWriter.
    Inherited from CompilerBase 
								 | 
							
