Package icyllis.arc3d.compiler
Class Context
java.lang.Object
icyllis.arc3d.compiler.Context
Contains objects and state associated with
ShaderCompiler
(i.e. Parser
or CodeGenerator).-
Method Summary
Modifier and TypeMethodDescriptionconvertIdentifier
(int position, String name) Create expressions with the given identifier name and current symbol table.void
Enters a scope level.void
void
Returns the ErrorHandler which will be notified of any errors that occur during DSL calls.getKind()
Returns the current SymbolTable.getTypes()
Returns the BuiltinTypes used by DSL operations in the current thread.boolean
isActive()
Returns true if the DSL has been started.boolean
boolean
isModule()
void
Leaves a scope level.void
setErrorHandler
(ErrorHandler errorHandler) Installs an ErrorHandler which will be notified of any errors that occur during DSL calls.void
void
-
Method Details
-
isActive
public boolean isActive()Returns true if the DSL has been started. -
getKind
-
getOptions
-
isBuiltin
public boolean isBuiltin()- Returns:
- true if we are at built-in level
-
isModule
public boolean isModule()- Returns:
- true if we are processing include files
-
getTypes
Returns the BuiltinTypes used by DSL operations in the current thread. -
getSymbolTable
Returns the current SymbolTable. -
enterScope
public void enterScope()Enters a scope level. -
leaveScope
public void leaveScope()Leaves a scope level. -
error
-
error
-
warning
-
warning
-
getErrorHandler
Returns the ErrorHandler which will be notified of any errors that occur during DSL calls. The default error handler throws RuntimeException on any error. -
setErrorHandler
Installs an ErrorHandler which will be notified of any errors that occur during DSL calls. -
convertIdentifier
Create expressions with the given identifier name and current symbol table. Report errors viaErrorHandler
; return null on error.
-