class_body
{ "{"
field_declaration
modifiers
private "private"
static "static"
final "final"
type_identifier "String"
variable_declarator
identifier "LT_ESCAPED"
= "="
string_literal
" "\""
escape_sequence "\\\\"
string_fragment "x3c"
" "\""
; ";"
field_declaration
modifiers
private "private"
static "static"
final "final"
type_identifier "String"
variable_declarator
identifier "GT_ESCAPED"
= "="
string_literal
" "\""
escape_sequence "\\\\"
string_fragment "x3e"
" "\""
; ";"
line_comment "// A memoizer for formatting strings as JS strings."
field_declaration (+23 nodes collapsed)
field_declaration (+49 nodes collapsed)
field_declaration
modifiers
private "private"
final "final"
type_identifier "CodeConsumer"
variable_declarator
identifier "cc"
; ";"
field_declaration
modifiers
private "private"
final "final"
type_identifier "CharsetEncoder"
variable_declarator
identifier "outputCharsetEncoder"
; ";"
field_declaration
modifiers
private "private"
final "final"
boolean_type "boolean"
variable_declarator
identifier "preferSingleQuotes"
; ";"
field_declaration
modifiers
private "private"
final "final"
boolean_type "boolean"
variable_declarator
identifier "trustedStrings"
; ";"
field_declaration
modifiers
private "private"
final "final"
type_identifier "LanguageMode"
variable_declarator
identifier "languageMode"
; ";"
constructor_declaration (+46 nodes collapsed)
method_declaration (+24 nodes collapsed)
constructor_declaration (+126 nodes collapsed)
block_comment "/**\n * Insert a ECMASCRIPT 5 strict annotation.\n */"
method_declaration (+22 nodes collapsed)
method_declaration (+22 nodes collapsed)
method_declaration (+29 nodes collapsed)
method_declaration (+25 nodes collapsed)
method_declaration
void_type "void"
identifier "add"
formal_parameters
( "("
formal_parameter
type_identifier "Node"
identifier "n"
, ","
formal_parameter
type_identifier "Context"
identifier "context"
) ")"
block
{ "{"
if_statement
if "if"
parenthesized_expression
( "("
unary_expression
! "!"
method_invocation
identifier "cc"
. "."
identifier "continueProcessing"
argument_list
( "("
) ")"
) ")"
block
{ "{"
return_statement
return "return"
; ";"
} "}"
local_variable_declaration
integral_type
int "int"
variable_declarator
identifier "type"
= "="
method_invocation
identifier "n"
. "."
identifier "getType"
argument_list
( "("
) ")"
; ";"
local_variable_declaration
type_identifier "String"
variable_declarator
identifier "opstr"
= "="
method_invocation
identifier "NodeUtil"
. "."
identifier "opToStr"
argument_list
( "("
identifier "type"
) ")"
; ";"
local_variable_declaration
integral_type
int "int"
variable_declarator
identifier "childCount"
= "="
method_invocation
identifier "n"
. "."
identifier "getChildCount"
argument_list
( "("
) ")"
; ";"
local_variable_declaration
type_identifier "Node"
variable_declarator
identifier "first"
= "="
method_invocation
identifier "n"
. "."
identifier "getFirstChild"
argument_list
( "("
) ")"
; ";"
local_variable_declaration
type_identifier "Node"
variable_declarator
identifier "last"
= "="
method_invocation
identifier "n"
. "."
identifier "getLastChild"
argument_list
( "("
) ")"
; ";"
line_comment "// Handle all binary operators"
if_statement (+234 nodes collapsed)
expression_statement
method_invocation
identifier "cc"
. "."
identifier "startSourceMapping"
argument_list
( "("
identifier "n"
) ")"
; ";"
switch_expression
switch "switch"
parenthesized_expression
( "("
identifier "type"
) ")"
switch_block
{ "{"
switch_block_statement_group (+173 nodes collapsed)
switch_block_statement_group (+67 nodes collapsed)
switch_block_statement_group (+55 nodes collapsed)
switch_block_statement_group (+68 nodes collapsed)
switch_block_statement_group (+51 nodes collapsed)
switch_block_statement_group (+49 nodes collapsed)
switch_block_statement_group (+155 nodes collapsed)
switch_block_statement_group (+41 nodes collapsed)
switch_block_statement_group (+41 nodes collapsed)
switch_block_statement_group (+55 nodes collapsed)
switch_block_statement_group (+40 nodes collapsed)
switch_block_statement_group
switch_label
case "case"
field_access
identifier "Token"
. "."
identifier "TYPEOF"
: ":"
switch_block_statement_group
switch_label
case "case"
field_access
identifier "Token"
. "."
identifier "VOID"
: ":"
switch_block_statement_group
switch_label
case "case"
field_access
identifier "Token"
. "."
identifier "NOT"
: ":"
switch_block_statement_group
switch_label
case "case"
field_access
identifier "Token"
. "."
identifier "BITNOT"
: ":"
switch_block_statement_group (+69 nodes collapsed)
switch_block_statement_group (+120 nodes collapsed)
switch_block_statement_group
switch_label
case "case"
field_access
identifier "Token"
. "."
identifier "HOOK"
: ":"
block
{ "{"
expression_statement
method_invocation
identifier "Preconditions"
. "."
identifier "checkState"
argument_list
( "("
binary_expression
identifier "childCount"
== "=="
decimal_integer_literal "3"
) ")"
; ";"
local_variable_declaration
integral_type
int "int"
variable_declarator
identifier "p"
= "="
method_invocation
identifier "NodeUtil"
. "."
identifier "precedence"
argument_list
( "("
identifier "type"
) ")"
; ";"
local_variable_declaration
type_identifier "Context"
variable_declarator
identifier "rhsContext"
= "="
field_access
identifier "Context"
. "."
identifier "OTHER"
; ";"
expression_statement
method_invocation
identifier "addExpr"
argument_list
( "("
identifier "first"
, ","
binary_expression
identifier "p"
+ "+"
decimal_integer_literal "1"
, ","
identifier "context"
) ")"
; ";"
expression_statement
method_invocation
identifier "cc"
. "."
identifier "addOp"
argument_list
( "("
string_literal
" "\""
string_fragment "?"
" "\""
, ","
true "true"
) ")"
; ";"
expression_statement
method_invocation
identifier "addExpr"
argument_list
( "("
method_invocation
identifier "first"
. "."
identifier "getNext"
argument_list
( "("
) ")"
, ","
decimal_integer_literal "1"
, ","
identifier "rhsContext"
) ")"
; ";"
expression_statement
method_invocation
identifier "cc"
. "."
identifier "addOp"
argument_list
( "("
string_literal
" "\""
string_fragment ":"
" "\""
, ","
true "true"
) ")"
; ";"
expression_statement
method_invocation
identifier "addExpr"
argument_list
( "("
identifier "last"
, ","
decimal_integer_literal "1"
, ","
identifier "rhsContext"
) ")"
; ";"
break_statement
break "break"
; ";"
} "}"
switch_block_statement_group (+127 nodes collapsed)
switch_block_statement_group (+176 nodes collapsed)
switch_block_statement_group
switch_label
case "case"
field_access
identifier "Token"
. "."
identifier "GETTER_DEF"
: ":"
switch_block_statement_group (+357 nodes collapsed)
switch_block_statement_group
switch_label
case "case"
field_access
identifier "Token"
. "."
identifier "SCRIPT"
: ":"
switch_block_statement_group (+281 nodes collapsed)
switch_block_statement_group (+254 nodes collapsed)
switch_block_statement_group (+89 nodes collapsed)
switch_block_statement_group (+71 nodes collapsed)
switch_block_statement_group (+24 nodes collapsed)
switch_block_statement_group (+224 nodes collapsed)
switch_block_statement_group (+86 nodes collapsed)
switch_block_statement_group (+71 nodes collapsed)
switch_block_statement_group
switch_label
case "case"
field_access
identifier "Token"
. "."
identifier "INC"
: ":"
switch_block_statement_group (+138 nodes collapsed)
switch_block_statement_group (+163 nodes collapsed)
switch_block_statement_group (+201 nodes collapsed)
switch_block_statement_group (+37 nodes collapsed)
switch_block_statement_group (+35 nodes collapsed)
switch_block_statement_group (+37 nodes collapsed)
switch_block_statement_group (+37 nodes collapsed)
switch_block_statement_group (+105 nodes collapsed)
switch_block_statement_group (+44 nodes collapsed)
switch_block_statement_group (+105 nodes collapsed)
switch_block_statement_group (+46 nodes collapsed)
switch_block_statement_group (+159 nodes collapsed)
switch_block_statement_group (+37 nodes collapsed)
switch_block_statement_group (+37 nodes collapsed)
switch_block_statement_group (+43 nodes collapsed)
switch_block_statement_group (+377 nodes collapsed)
switch_block_statement_group (+80 nodes collapsed)
switch_block_statement_group (+51 nodes collapsed)
switch_block_statement_group (+43 nodes collapsed)
switch_block_statement_group (+90 nodes collapsed)
switch_block_statement_group (+41 nodes collapsed)
switch_block_statement_group (+35 nodes collapsed)
} "}"
expression_statement
method_invocation
identifier "cc"
. "."
identifier "endSourceMapping"
argument_list
( "("
identifier "n"
) ")"
; ";"
} "}"
block_comment "/**\n * We could use addList recursively here, but sometime"...
method_declaration (+165 nodes collapsed)
method_declaration (+124 nodes collapsed)
method_declaration (+87 nodes collapsed)
block_comment "/**\n * @return Whether the name is an indirect eval.\n */"
method_declaration (+58 nodes collapsed)
block_comment "/**\n * Adds a block or expression, substituting a VOID wit"...
method_declaration (+387 nodes collapsed)
block_comment "/**\n * @return Whether the Node is a DO or FUNCTION (with "...
method_declaration (+144 nodes collapsed)
method_declaration (+124 nodes collapsed)
method_declaration (+27 nodes collapsed)
method_declaration (+31 nodes collapsed)
method_declaration (+120 nodes collapsed)
block_comment "/**\n * This function adds a comma-separated list as is spe"...
method_declaration (+114 nodes collapsed)
method_declaration (+38 nodes collapsed)
method_declaration (+49 nodes collapsed)
block_comment "/** Outputs a JS string, using the optimal (single/double) q"...
method_declaration (+143 nodes collapsed)
method_declaration (+226 nodes collapsed)
block_comment "/** Escapes regular expression */"
method_declaration (+48 nodes collapsed)
block_comment "/**\n * Escapes the given string to a double quoted (\") Jav"...
method_declaration (+46 nodes collapsed)
block_comment "/* If the user doesn't want to specify an output charset enc"...
method_declaration (+23 nodes collapsed)
block_comment "/** Helper to escape JavaScript string as well as regular ex"...
method_declaration (+954 nodes collapsed)
method_declaration (+147 nodes collapsed)
block_comment "/**\n * @param maxCount The maximum number of children to l"...
method_declaration (+129 nodes collapsed)
block_comment "/** Gets the first non-empty child of the given node. */"
method_declaration (+119 nodes collapsed)
line_comment "// Information on the current context. Used for disambiguati"...
line_comment "// For example, a \"{\" could indicate the start of an object "...
line_comment "// block, depending on the current context."
enum_declaration (+27 nodes collapsed)
method_declaration (+35 nodes collapsed)
block_comment "/**\n * If we're in a IN_FOR_INIT_CLAUSE, we can't permit i"...
method_declaration (+38 nodes collapsed)
block_comment "/**\n * @see #appendHexJavaScriptRepresentation(int, Append"...
method_declaration (+57 nodes collapsed)
block_comment "/**\n * Returns a JavaScript representation of the characte"...
method_declaration (+181 nodes collapsed)
} "}"