C# Class Jurassic.Compiler.EvalMethodGenerator

Represents the information needed to compile eval script into a method.
Inheritance: MethodGenerator
Mostrar archivo Open project: paulbartrum/jurassic

Public Methods

Method Description
EvalMethodGenerator ( ScriptEngine engine, Scope parentScope, ScriptSource source, Jurassic.Compiler.CompilerOptions options, object thisObject ) : System

Creates a new EvalMethodGenerator instance.

Execute ( ) : object

Executes the script.

Parse ( ) : void

Parses the source text into an abstract syntax tree.

Protected Methods

Method Description
GenerateCode ( ILGenerator generator, OptimizationInfo optimizationInfo ) : void

Generates IL for the script.

GetMethodName ( ) : string

Gets a name for the generated method.

Method Details

EvalMethodGenerator() public method

Creates a new EvalMethodGenerator instance.
public EvalMethodGenerator ( ScriptEngine engine, Scope parentScope, ScriptSource source, Jurassic.Compiler.CompilerOptions options, object thisObject ) : System
engine ScriptEngine The script engine.
parentScope Scope The scope of the calling code.
source ScriptSource The script code to execute.
options Jurassic.Compiler.CompilerOptions Options that influence the compiler.
thisObject object The value of the "this" keyword in the calling code.
return System

Execute() public method

Executes the script.
public Execute ( ) : object
return object

GenerateCode() protected method

Generates IL for the script.
protected GenerateCode ( ILGenerator generator, OptimizationInfo optimizationInfo ) : void
generator ILGenerator The generator to output the CIL to.
optimizationInfo OptimizationInfo Information about any optimizations that should be performed.
return void

GetMethodName() protected method

Gets a name for the generated method.
protected GetMethodName ( ) : string
return string

Parse() public method

Parses the source text into an abstract syntax tree.
public Parse ( ) : void
return void