org.jetbrains.k2js.translate.context
Class TranslationContext
java.lang.Object
org.jetbrains.k2js.translate.context.TranslationContext
public class TranslationContext
- extends java.lang.Object
All the info about the state of the translation process.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
rootContext
@NotNull
public static TranslationContext rootContext(@NotNull
StaticContext staticContext,
com.google.dart.compiler.backend.js.ast.JsFunction rootFunction)
isEcma5
public boolean isEcma5()
usageTracker
public UsageTracker usageTracker()
dynamicContext
public DynamicContext dynamicContext()
contextWithScope
@NotNull
public TranslationContext contextWithScope(@NotNull
com.google.dart.compiler.backend.js.ast.JsFunction fun)
newFunctionBody
@NotNull
public TranslationContext newFunctionBody(@NotNull
com.google.dart.compiler.backend.js.ast.JsFunction fun,
@Nullable
AliasingContext aliasingContext,
@Nullable
UsageTracker usageTracker)
innerBlock
@NotNull
public TranslationContext innerBlock(@NotNull
com.google.dart.compiler.backend.js.ast.JsBlock block)
newDeclaration
@NotNull
public TranslationContext newDeclaration(@NotNull
DeclarationDescriptor descriptor)
innerContextWithThisAliased
@NotNull
public TranslationContext innerContextWithThisAliased(@NotNull
DeclarationDescriptor correspondingDescriptor,
@NotNull
com.google.dart.compiler.backend.js.ast.JsNameRef alias)
innerContextWithAliasesForExpressions
@NotNull
public TranslationContext innerContextWithAliasesForExpressions(@NotNull
java.util.Map<JetExpression,com.google.dart.compiler.backend.js.ast.JsName> aliases)
innerContextWithDescriptorsAliased
@NotNull
public TranslationContext innerContextWithDescriptorsAliased(@NotNull
java.util.Map<DeclarationDescriptor,com.google.dart.compiler.backend.js.ast.JsExpression> aliases)
getBlockForDescriptor
@NotNull
public com.google.dart.compiler.backend.js.ast.JsBlock getBlockForDescriptor(@NotNull
DeclarationDescriptor descriptor)
bindingContext
@NotNull
public BindingContext bindingContext()
getScopeForDescriptor
@NotNull
public com.google.dart.compiler.backend.js.ast.JsScope getScopeForDescriptor(@NotNull
DeclarationDescriptor descriptor)
getNameForElement
@NotNull
public com.google.dart.compiler.backend.js.ast.JsName getNameForElement(@NotNull
com.intellij.psi.PsiElement element)
getNameForDescriptor
@NotNull
public com.google.dart.compiler.backend.js.ast.JsName getNameForDescriptor(@NotNull
DeclarationDescriptor descriptor)
nameToLiteral
@NotNull
public com.google.dart.compiler.backend.js.ast.JsStringLiteral nameToLiteral(@NotNull
Named named)
getQualifierForDescriptor
@Nullable
public com.google.dart.compiler.backend.js.ast.JsNameRef getQualifierForDescriptor(@NotNull
DeclarationDescriptor descriptor)
declareTemporary
@NotNull
public TemporaryVariable declareTemporary(@Nullable
com.google.dart.compiler.backend.js.ast.JsExpression initExpression)
getOrDeclareTemporaryConstVariable
@NotNull
public TemporaryConstVariable getOrDeclareTemporaryConstVariable(@NotNull
com.google.dart.compiler.backend.js.ast.JsExpression expression)
associateExpressionToLazyValue
public void associateExpressionToLazyValue(com.google.dart.compiler.backend.js.ast.JsExpression expression,
TemporaryConstVariable temporaryConstVariable)
namer
@NotNull
public Namer namer()
intrinsics
@NotNull
public Intrinsics intrinsics()
program
@NotNull
public com.google.dart.compiler.backend.js.ast.JsProgram program()
scope
@NotNull
public com.google.dart.compiler.backend.js.ast.JsScope scope()
aliasingContext
@NotNull
public AliasingContext aliasingContext()
literalFunctionTranslator
@NotNull
public LiteralFunctionTranslator literalFunctionTranslator()
getFunctionObject
@NotNull
public com.google.dart.compiler.backend.js.ast.JsFunction getFunctionObject(@NotNull
CallableDescriptor descriptor)
addStatementToCurrentBlock
public void addStatementToCurrentBlock(@NotNull
com.google.dart.compiler.backend.js.ast.JsStatement statement)
getAliasForDescriptor
public com.google.dart.compiler.backend.js.ast.JsExpression getAliasForDescriptor(@NotNull
DeclarationDescriptor descriptor)
getThisObject
@NotNull
public com.google.dart.compiler.backend.js.ast.JsExpression getThisObject(@NotNull
DeclarationDescriptor descriptor)