Package com.google.javascript.jscomp
Class CodeGenerator
java.lang.Object
com.google.javascript.jscomp.CodeGenerator
CodeGenerator generates codes from a parse tree, sending it to the specified CodeConsumer.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enum
Information on the current context. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
CodeGenerator
(CodeConsumer consumer, CompilerOptions options) -
Method Summary
Modifier and TypeMethodDescriptionprotected void
protected void
add
(Node node, CodeGenerator.Context context) protected void
add
(Node node, CodeGenerator.Context context, boolean printComments) Generate the current nodeprotected void
protected void
Print Leading JSDocComments or NonJSDocComments for the given node in order, depending on their source location.protected void
printTrailingComment
(Node node) void
Insert a ECMASCRIPT 5 strict annotation.
-
Constructor Details
-
CodeGenerator
-
-
Method Details
-
tagAsStrict
public void tagAsStrict()Insert a ECMASCRIPT 5 strict annotation. -
printLeadingCommentsInOrder
Print Leading JSDocComments or NonJSDocComments for the given node in order, depending on their source location. -
printTrailingComment
-
add
-
add
-
add
-
add
Generate the current node
-