Class AbstractCompilationUnitBuilder
java.lang.Object
com.google.j2cl.transpiler.frontend.common.AbstractCompilationUnitBuilder
Base class for implementing that AST conversion from different front ends.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected com.google.j2cl.transpiler.ast.CompilationUnitprotected Stringprotected com.google.j2cl.transpiler.ast.TypeReturns the current type.protected ErrorinternalCompilerError(String format, Object... params) protected ErrorinternalCompilerError(Throwable e, String format, Object... params) protected StringinternalCompilerErrorMessage(String format, Object... params) protected <T> TprocessEnclosedBy(com.google.j2cl.transpiler.ast.Type type, Supplier<T> supplier) Invokesupplierwithtypein the type stack.protected voidsetCurrentCompilationUnit(com.google.j2cl.transpiler.ast.CompilationUnit currentCompilationUnit) protected voidsetCurrentSourceFile(String currentSourceFile) protected static com.google.j2cl.transpiler.ast.VariableDeclarationExpressiontoResource(com.google.j2cl.transpiler.ast.Expression expression) Creates temporary variables for a resource that is declared outside of the try-catch statement.
-
Constructor Details
-
AbstractCompilationUnitBuilder
public AbstractCompilationUnitBuilder()
-
-
Method Details
-
getCurrentSourceFile
-
setCurrentSourceFile
-
getCurrentCompilationUnit
protected com.google.j2cl.transpiler.ast.CompilationUnit getCurrentCompilationUnit() -
setCurrentCompilationUnit
protected void setCurrentCompilationUnit(com.google.j2cl.transpiler.ast.CompilationUnit currentCompilationUnit) -
processEnclosedBy
Invokesupplierwithtypein the type stack. -
getCurrentType
protected com.google.j2cl.transpiler.ast.Type getCurrentType()Returns the current type. -
toResource
protected static com.google.j2cl.transpiler.ast.VariableDeclarationExpression toResource(com.google.j2cl.transpiler.ast.Expression expression) Creates temporary variables for a resource that is declared outside of the try-catch statement. -
internalCompilerError
-
internalCompilerError
-
internalCompilerErrorMessage
-