C# Класс Evaluator.Eval

A class providing static methods for the language-independent runtime compilation of .NET source code.
Показать файл Открыть проект

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

Метод Описание
CreateAssembly ( ICodeCompiler compiler, string assemblySource, CompilerParameters options, Language language ) : AssemblyResults

Compiles an assembly from the provided source with the parameters specified.

CreateMethod ( ICodeCompiler compiler, string methodSource, string methodName, CompilerParameters options, Language language ) : MethodResults

Compiles a method from the provided source with the parameters specified.

CreateType ( ICodeCompiler compiler, string typeSource, string typeName, CompilerParameters options, Language language ) : TypeResults

Compiles a type (or class) from the provided source with the parameters specified.

CreateVirtualAssembly ( ICodeCompiler compiler, string assemblySource, Language language, bool debug ) : AssemblyResults

Compiles an assembly from the provided source and stores it in memory using the parameters specified.

CreateVirtualMethod ( ICodeCompiler compiler, string methodSource, string methodName, Language language, bool debug ) : MethodResults

Compiles a method from the provided source and stores it in memory with the parameters specified.

CreateVirtualType ( ICodeCompiler compiler, string typeSource, string typeName, Language language, bool debug ) : TypeResults

Compiles a type (or class) from the provided source and stores it in memory using the parameters specified.

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

Метод Описание
GetVirtualParameters ( bool debug, string assemblyName ) : CompilerParameters

Creates a CompilerParameters object containing the default settings for an assembly generated in memory.

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

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

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

CreateAssembly() публичный статический Метод

Compiles an assembly from the provided source with the parameters specified.
public static CreateAssembly ( ICodeCompiler compiler, string assemblySource, CompilerParameters options, Language language ) : AssemblyResults
compiler ICodeCompiler /// The compiler to use for compiling the source to MSIL. ///
assemblySource string /// The actual source of the assembly. ///
options System.CodeDom.Compiler.CompilerParameters /// The parameters to be set for the compiler. ///
language Language /// A specification of the syntax of the language of the code ///
Результат AssemblyResults

CreateMethod() публичный статический Метод

Compiles a method from the provided source with the parameters specified.
public static CreateMethod ( ICodeCompiler compiler, string methodSource, string methodName, CompilerParameters options, Language language ) : MethodResults
compiler ICodeCompiler /// The compiler to use for compiling the source to MSIL. ///
methodSource string /// The actual source of the method. ///
methodName string /// The name of the method. ///
options System.CodeDom.Compiler.CompilerParameters /// The parameters to be set for the compiler. ///
language Language /// A specification of the syntax of the language of the code ///
Результат MethodResults

CreateType() публичный статический Метод

Compiles a type (or class) from the provided source with the parameters specified.
public static CreateType ( ICodeCompiler compiler, string typeSource, string typeName, CompilerParameters options, Language language ) : TypeResults
compiler ICodeCompiler /// The compiler to use for compiling the source to MSIL. ///
typeSource string /// The actual source of the type. ///
typeName string /// The name of the type. ///
options System.CodeDom.Compiler.CompilerParameters /// The parameters to be set for the compiler. ///
language Language /// A specification of the syntax of the language of the code ///
Результат TypeResults

CreateVirtualAssembly() публичный статический Метод

Compiles an assembly from the provided source and stores it in memory using the parameters specified.
public static CreateVirtualAssembly ( ICodeCompiler compiler, string assemblySource, Language language, bool debug ) : AssemblyResults
compiler ICodeCompiler /// The compiler to use for compiling the source to MSIL. ///
assemblySource string /// The actual source of the assembly. ///
language Language /// A specification of the syntax of the language of the code ///
debug bool /// Determines whether debug information is included in the compiled assembly. ///
Результат AssemblyResults

CreateVirtualMethod() публичный статический Метод

Compiles a method from the provided source and stores it in memory with the parameters specified.
public static CreateVirtualMethod ( ICodeCompiler compiler, string methodSource, string methodName, Language language, bool debug ) : MethodResults
compiler ICodeCompiler /// The compiler to use for compiling the source to MSIL. ///
methodSource string /// The actual source of the method. ///
methodName string /// The name of the method. ///
language Language /// A specification of the syntax of the language of the code ///
debug bool /// Determines whether debug information is included in the compiled assembly. ///
Результат MethodResults

CreateVirtualType() публичный статический Метод

Compiles a type (or class) from the provided source and stores it in memory using the parameters specified.
public static CreateVirtualType ( ICodeCompiler compiler, string typeSource, string typeName, Language language, bool debug ) : TypeResults
compiler ICodeCompiler /// The compiler to use for compiling the source to MSIL. ///
typeSource string /// The actual source of the type. ///
typeName string /// The name of the type. ///
language Language /// A specification of the syntax of the language of the code ///
debug bool /// Determines whether debug information is included in the compiled assembly. ///
Результат TypeResults

GetVirtualParameters() защищенный статический Метод

Creates a CompilerParameters object containing the default settings for an assembly generated in memory.
protected static GetVirtualParameters ( bool debug, string assemblyName ) : CompilerParameters
debug bool /// Determines whether debug information is included in the compiler's final output. ///
assemblyName string /// The name of the resulting assembly. ///
Результат System.CodeDom.Compiler.CompilerParameters