Class RoslynCompiler
- Namespace
- Ecng.Compilation.Roslyn
- Assembly
- Ecng.Compilation.Roslyn.dll
Represents a Roslyn compiler.
public abstract class RoslynCompiler : ICompiler
- Inheritance
-
RoslynCompiler
- Implements
- Derived
- Inherited Members
- Extension Methods
Constructors
RoslynCompiler(string)
Represents a Roslyn compiler.
protected RoslynCompiler(string extension)
Parameters
extension
stringThe file extension of the source files that the compiler supports.
Properties
IsCaseSensitive
Gets a value indicating whether the language is case sensitive.
public abstract bool IsCaseSensitive { get; }
Property Value
IsReferencesSupported
Gets a value indicating whether the compiler supports external references.
public abstract bool IsReferencesSupported { get; }
Property Value
IsTabsSupported
Gets a value indicating whether the compiler supports tabs in the source code.
public abstract bool IsTabsSupported { get; }
Property Value
Methods
Create(string, IEnumerable<string>, PortableExecutableReference[], CancellationToken)
Creates a new compilation instance.
protected abstract Compilation Create(string assemblyName, IEnumerable<string> sources, PortableExecutableReference[] references, CancellationToken cancellationToken)
Parameters
assemblyName
stringThe name of the assembly.
sources
IEnumerable<string>The source code files as strings.
references
PortableExecutableReference[]A collection of references.
cancellationToken
CancellationToken
Returns
- Compilation
Microsoft.CodeAnalysis.Compilation