Search Results for

    Show / Hide Table of Contents

    Class CodeCompiler

    Inheritance
    Object
    CodeCompiler
    Inherited Members
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Object.ReferenceEquals(Object, Object)
    Object.ToString()
    Namespace: Microsoft.ML.Probabilistic.Compiler
    Assembly: Microsoft.ML.Probabilistic.Compiler.dll
    Syntax
    public class CodeCompiler

    Fields

    compilerChoice

    Compiler to use: Roslyn or CodeDom.Compiler. Auto means CodeDom.Compiler on .NET full / Windows, and Roslyn on .NET Core and Mono.

    Declaration
    public CompilerChoice compilerChoice
    Field Value
    Type Description
    CompilerChoice

    GeneratedSourceFolder

    The absolute or relative path to the generated source code.

    Declaration
    public string GeneratedSourceFolder
    Field Value
    Type Description
    String

    generateInMemory

    If true, source code files are written out for each transformed class.

    Declaration
    public bool generateInMemory
    Field Value
    Type Description
    Boolean

    includeDebugInformation

    If true, causes the C# compiler to include debug information in the generated DLL.

    Declaration
    public bool includeDebugInformation
    Field Value
    Type Description
    Boolean

    language

    The language that we'll compile

    Declaration
    protected string language
    Field Value
    Type Description
    String

    optimizeCode

    If true, causes the C# compiler to generate optimized code

    Declaration
    public bool optimizeCode
    Field Value
    Type Description
    Boolean

    runningOnMono

    Declaration
    protected bool runningOnMono
    Field Value
    Type Description
    Boolean

    runningOnNetCore

    Declaration
    protected bool runningOnNetCore
    Field Value
    Type Description
    Boolean

    showProgress

    If true, print messages about compilation progress.

    Declaration
    public bool showProgress
    Field Value
    Type Description
    Boolean

    useExistingFiles

    If true, existing source code files are used.

    Declaration
    public bool useExistingFiles
    Field Value
    Type Description
    Boolean

    writeSourceFiles

    If true, source code files are written out for each transformed class.

    Declaration
    public bool writeSourceFiles
    Field Value
    Type Description
    Boolean

    Methods

    Compile(List<String>, List<String>, ICollection<Assembly>)

    Declaration
    public CompilerResults Compile(List<string> filenames, List<string> sources, ICollection<Assembly> referencedAssemblies)
    Parameters
    Type Name Description
    List<String> filenames
    List<String> sources
    ICollection<Assembly> referencedAssemblies
    Returns
    Type Description
    CompilerResults

    ExpressionToString(IExpression)

    Declaration
    public static string ExpressionToString(IExpression expr)
    Parameters
    Type Name Description
    IExpression expr
    Returns
    Type Description
    String

    GetCompiledType(CompilerResults, ITypeDeclaration)

    Declaration
    public static Type GetCompiledType(CompilerResults cr, ITypeDeclaration decl)
    Parameters
    Type Name Description
    CompilerResults cr
    ITypeDeclaration decl
    Returns
    Type Description
    Type

    GetFilenameForType(String, ITypeDeclaration, String)

    Declaration
    public static string GetFilenameForType(string folder, ITypeDeclaration td, string suffix)
    Parameters
    Type Name Description
    String folder
    ITypeDeclaration td
    String suffix
    Returns
    Type Description
    String

    WriteAndCompile(List<ITypeDeclaration>)

    Declaration
    public CompilerResults WriteAndCompile(List<ITypeDeclaration> typeDeclarations)
    Parameters
    Type Name Description
    List<ITypeDeclaration> typeDeclarations
    Returns
    Type Description
    CompilerResults

    WriteSource(List<ITypeDeclaration>, IList<String>, out ICollection<Assembly>)

    Declaration
    public List<string> WriteSource(List<ITypeDeclaration> typeDeclarations, IList<string> filenames, out ICollection<Assembly> referencedAssemblies)
    Parameters
    Type Name Description
    List<ITypeDeclaration> typeDeclarations
    IList<String> filenames
    ICollection<Assembly> referencedAssemblies
    Returns
    Type Description
    List<String>
    In This Article
    Back to top Copyright © .NET Foundation. All rights reserved.