C# Класс Blamite.Blam.Scripting.Compiler.ScriptCompiler

Наследование: HS_Gen1BaseListener
Показать файл Открыть проект

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

Метод Описание
EnterBranch ( HS_Gen1Parser.BranchContext context ) : void
EnterCall ( HS_Gen1Parser.CallContext context ) : void

Processes function calls and script references. Links to a datum. Opens one or more datums. Pops a value type. Pushes parameter types.

EnterCond ( HS_Gen1Parser.CondContext context ) : void
EnterCondGroup ( HS_Gen1Parser.CondGroupContext context ) : void
EnterGlobalDeclaration ( HS_Gen1Parser.GlobalDeclarationContext context ) : void

Processes global declarations. Opens a datum. Creates the global node. Pushes the value type.

EnterHsc ( HS_Gen1Parser.HscContext context ) : void

Generate script and global lookups.

EnterLiteral ( HS_Gen1Parser.LiteralContext context ) : void

Processes regular expressions, script variables and global references. Links to a datum. Opens a datum.

EnterScriptDeclaration ( HS_Gen1Parser.ScriptDeclarationContext context ) : void

Processes script declarations. Opens a datum. Creates the script node and the initial "begin" expression. Generates the variable lookup. Pushes return types.

ExitBranch ( HS_Gen1Parser.BranchContext context ) : void
ExitCall ( HS_Gen1Parser.CallContext context ) : void

Closes a datum.

ExitCond ( HS_Gen1Parser.CondContext context ) : void
ExitCondGroup ( HS_Gen1Parser.CondGroupContext context ) : void
ExitGlobalDeclaration ( HS_Gen1Parser.GlobalDeclarationContext context ) : void

Closes a datum.

ExitHsc ( HS_Gen1Parser.HscContext context ) : void

Output Debug Info

ExitScriptDeclaration ( HS_Gen1Parser.ScriptDeclarationContext context ) : void

Closes a datum.

Result ( ) : ScriptData
ScriptCompiler ( ICacheFile casheFile, EngineDescription buildInfo, OpcodeLookup opCodes, ScriptingContextCollection context, IProgress progress, ScriptCompilerLogger logger, bool debug ) : System

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

Метод Описание
CreateFunctionCall ( FunctionInfo info, ushort returnTypeOpcode, uint textPosition, short lineNumber ) : void
CreateInitialBegin ( string returnType, uint textPosition ) : void
CreateScriptReference ( Blamite.Blam.Scripting.Compiler.ScriptInfo info, ushort returnTypeOpcode, uint textPosition, short lineNumber ) : void
DetermineReturnType ( IScriptingConstantInfo info, string expectedType, ParserRuleContext context ) : string
GenerateBranches ( ) : void
GetEqualityArgumentOP ( ushort normalOpcode ) : ushort
GetGlobalOpCode ( ushort globalOpcode, RuleContext context ) : ushort
IsGlobalsReference ( string expectedType, ParserRuleContext context ) : bool
IsScriptParameter ( string expectedReturnType, ParserRuleContext context ) : bool
IsScriptReference ( string expectedReturnType, int expectedParameterCount, HS_Gen1Parser.CallContext context ) : bool
PushCallParameters ( FunctionInfo info, int contextParameterCount, string expectedReturnType, HS_Gen1Parser.CallContext context ) : void

Calculates the value types for the parameters of a function and pushes them to the stack.

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

EnterBranch() публичный Метод

public EnterBranch ( HS_Gen1Parser.BranchContext context ) : void
context HS_Gen1Parser.BranchContext
Результат void

EnterCall() публичный Метод

Processes function calls and script references. Links to a datum. Opens one or more datums. Pops a value type. Pushes parameter types.
public EnterCall ( HS_Gen1Parser.CallContext context ) : void
context HS_Gen1Parser.CallContext
Результат void

EnterCond() публичный Метод

public EnterCond ( HS_Gen1Parser.CondContext context ) : void
context HS_Gen1Parser.CondContext
Результат void

EnterCondGroup() публичный Метод

public EnterCondGroup ( HS_Gen1Parser.CondGroupContext context ) : void
context HS_Gen1Parser.CondGroupContext
Результат void

EnterGlobalDeclaration() публичный Метод

Processes global declarations. Opens a datum. Creates the global node. Pushes the value type.
public EnterGlobalDeclaration ( HS_Gen1Parser.GlobalDeclarationContext context ) : void
context HS_Gen1Parser.GlobalDeclarationContext
Результат void

EnterHsc() публичный Метод

Generate script and global lookups.
public EnterHsc ( HS_Gen1Parser.HscContext context ) : void
context HS_Gen1Parser.HscContext
Результат void

EnterLiteral() публичный Метод

Processes regular expressions, script variables and global references. Links to a datum. Opens a datum.
public EnterLiteral ( HS_Gen1Parser.LiteralContext context ) : void
context HS_Gen1Parser.LiteralContext
Результат void

EnterScriptDeclaration() публичный Метод

Processes script declarations. Opens a datum. Creates the script node and the initial "begin" expression. Generates the variable lookup. Pushes return types.
public EnterScriptDeclaration ( HS_Gen1Parser.ScriptDeclarationContext context ) : void
context HS_Gen1Parser.ScriptDeclarationContext
Результат void

ExitBranch() публичный Метод

public ExitBranch ( HS_Gen1Parser.BranchContext context ) : void
context HS_Gen1Parser.BranchContext
Результат void

ExitCall() публичный Метод

Closes a datum.
public ExitCall ( HS_Gen1Parser.CallContext context ) : void
context HS_Gen1Parser.CallContext
Результат void

ExitCond() публичный Метод

public ExitCond ( HS_Gen1Parser.CondContext context ) : void
context HS_Gen1Parser.CondContext
Результат void

ExitCondGroup() публичный Метод

public ExitCondGroup ( HS_Gen1Parser.CondGroupContext context ) : void
context HS_Gen1Parser.CondGroupContext
Результат void

ExitGlobalDeclaration() публичный Метод

Closes a datum.
public ExitGlobalDeclaration ( HS_Gen1Parser.GlobalDeclarationContext context ) : void
context HS_Gen1Parser.GlobalDeclarationContext
Результат void

ExitHsc() публичный Метод

Output Debug Info
public ExitHsc ( HS_Gen1Parser.HscContext context ) : void
context HS_Gen1Parser.HscContext
Результат void

ExitScriptDeclaration() публичный Метод

Closes a datum.
public ExitScriptDeclaration ( HS_Gen1Parser.ScriptDeclarationContext context ) : void
context HS_Gen1Parser.ScriptDeclarationContext
Результат void

Result() публичный Метод

public Result ( ) : ScriptData
Результат ScriptData

ScriptCompiler() публичный Метод

public ScriptCompiler ( ICacheFile casheFile, EngineDescription buildInfo, OpcodeLookup opCodes, ScriptingContextCollection context, IProgress progress, ScriptCompilerLogger logger, bool debug ) : System
casheFile ICacheFile
buildInfo EngineDescription
opCodes OpcodeLookup
context ScriptingContextCollection
progress IProgress
logger ScriptCompilerLogger
debug bool
Результат System