Anonymous function: An anonymous function, eg a lambda function, an arrow function, etc
Argument or parameter
Actual: An argument/parameter in a function call
Actual constructor: An argument/parameter in a constructor call
Actual constructor (iteration): Iteration scope of arguments in a constructor call, should be inside the parens of the argument list
Actual (iteration): Iteration scope of arguments in a function call, should be inside the parens of the argument list
Actual method: An argument/parameter in a method call
Actual method (iteration): Iteration scope of arguments in a method call, should be inside the parens of the argument list
Formal: A parameter in a function declaration
Formal constructor: A parameter in a constructor declaration
Formal constructor (iteration): Iteration scope of the formal parameters of a constructor declaration; should be the whole parameter list. The domain should be the entire function.
Formal (iteration): Iteration scope of the formal parameters of a function declaration; should be the whole parameter list. The domain should be the entire function.
Formal method: A parameter in a class method declaration
Formal method (iteration): Iteration scope of the formal parameters of a class method declaration; should be the whole parameter list. The domain should be the entire function.
Branch
If: An if/elif/else branch
If (iteration): Iteration scope for if/elif/else branch; should be the entire if-else statement
Switch case: A case/default branch in a switch/match statement
Switch case (iteration): Iteration scope for branches in a switch/match statement; should contain all the cases
Ternary: A branch in a ternary expression
Try: A try/catch/finally branch
Try (iteration): Iteration scope for try/catch/finally branch; should be the entire try-catch statement
Class
Class: A class in an object-oriented language
Class name
Class name: The name of a class
Collection item
Unenclosed: An item in a comma-separated list without enclosing delimiters. This could be multi-variable declarations, import statements, etc.
Collection key
Map pair: Key (LHS) of a key-value pair of a map
Map pair (iteration): Iteration scope of key-value pairs in a map; should be between the braces
Comment
Block: A block comment
Line: A line comment
Condition
Do while: A condition in a do while loop
For: A condition in a for loop
If: A condition in an if statement
Switch case: A condition in a switch statement
Switch case (iteration): The iteration scope for conditions in a switch statement: should contain all the cases, and exclude any curly brackets delimiting the full switch statement body
Ternary: A condition in a ternary expression
While: A condition in a while loop
Disqualify delimiter
Disqualify delimiter: Used to disqualify a token from being treated as a surrounding pair delimiter. This will usually be operators containing `>` or `<`, eg `<`, `<=`, `->`, etc
Function call
Function call: A function call
Constructor: A constructor call
Function callee
Function callee: The function being called in a function call
Constructor: The class being constructed in a class instantiation, including the `new` keyword
Function name
Function name: The name of a function
Constructor: The name of a constructor in a class
Iteration document: Iteration scope for function names: the entire document
Method: The name of a method in a class
Method iteration class: Iteration scope for method names: class bodies
If statement
If statement: An if statement
List
List: A list/array
Map
Map: A map/dictionary
Name
Argument formal: The name of a parameter in a function declaration
Argument formal constructor: The name of a parameter in a constructor declaration
Argument formal constructor (iteration): Iteration scope of the names of the formal parameters of a constructor declaration; should be the whole parameter list
Argument formal (iteration): Iteration scope of the names of the formal parameters of a function declaration; should be the whole parameter list
Argument formal method: The name of a parameter in a class method declaration
Argument formal method (iteration): Iteration scope of the names of the formal parameters of a class method declaration; should be the whole parameter list
Assignment: Name (LHS) of an assignment
Assignment pattern: LHS of an assignment with pattern destructuring
Class: Name of a class
Constructor: Name of a constructor
Field: Name (LHS) of a field in a class / interface
Foreach: Iteration variable name in a for each loop
Function: Name of a function
Iteration document: Iteration scope for names: the entire document
Method: Name of a class method
Variable: Name (LHS) of a variable declaration
Variable pattern: Name (LHS) of a variable declaration with pattern destructuring
Named function
Named function: A named function declaration
Constructor: A constructor declaration in a class
Iteration document: Iteration scope for named functions: the entire document
Method: A named method declaration in a class
Method iteration class: Iteration scope for named functions: class bodies
Statement: A statement, eg assignment, for loop, etc
Class: An class declaration
Iteration block: Iteration scope for statements. Statement blocks(body of functions/if statements/for loops/etc).
Iteration document: Iteration scope for statements. The entire document.
String
Multi line: A multi-line string
Single line: A single-line string
Text fragment
Comment block: Text fragment consisting of a block comment
Comment line: Text fragment consisting of a line comment
String multi line: Text fragment consisting of a multi-line string
String single line: Text fragment consisting of a single-line string
Type
Alias: A type alias declaration
Argument formal: Type of formal parameter in a function declaration
Argument formal constructor: Type of formal parameter in a constructor declaration
Argument formal constructor (iteration): Iteration scope of the types of the formal parameters of a constructor declaration; should be the whole parameter list
Argument formal (iteration): Iteration scope of the types of the formal parameters of a function declaration; should be the whole parameter list
Argument formal method: Type of formal parameter in a class method declaration
Argument formal method (iteration): Iteration scope of the types of the formal parameters of a class method declaration; should be the whole parameter list
Cast: A type cast
Enum: An enum declaration
Field: Type of field in a class / interface
Interface: An interface declaration
Return: Type of return value in a function declaration
Variable: Type of variable in a variable declaration
Value
Argument formal: The value of a (keyword) argument in a function declaration
Argument formal constructor: The value of a parameter in a constructor declaration
Argument formal constructor (iteration): Iteration scope of the values of the formal parameters of a constructor declaration; should be the whole parameter list
Argument formal (iteration): Iteration scope of the values of the formal parameters of a function declaration; should be the whole parameter list
Argument formal method: The value of a parameter in a class method declaration
Argument formal method (iteration): Iteration scope of the values of the formal parameters of a class method declaration; should be the whole parameter list
Assignment: Value (RHS) of an assignment
Field: Value (RHS) of a field in a class / interface
Foreach: Iterable in a for each loop
Map pair: Value (RHS) of a key-value pair in a map
Map pair (iteration): Iteration scope of key-value pairs in a map; should be between the braces
Return: Return value of a function
Return lambda: Implicit return value from a lambda
Type alias: Value of a type alias declaration
Variable: Value (RHS) of a variable declaration
Variable pattern: Value (RHS) of a variable declaration with pattern destructuring
Yield: Value of a yield statement
Unsupported facets
These facets are not supported yet and needs a developer to implement them