Package com.tonic.analysis.source.ast.expr
Expression nodes and their operators.
-
Interface Summary Interface Description Expression Sealed interface representing all expression types in the source AST. -
Class Summary Class Description ArrayAccessExpr An array access expression: array[index].ArrayInitExpr An array initializer expression: {elem1, elem2, ...}.BinaryExpr A binary expression: left op right, including assignments and logical operators.CastExpr A cast expression: (Type) expression.ClassExpr A class literal expression: Type.class.DynamicConstantExpr A dynamic constant (condy, Java 11+) whose bootstrap method was not a recognized pattern, preserving the bootstrap information for display.FieldAccessExpr A field access expression: obj.field or Type.staticField.InstanceOfExpr An instanceof expression: expression instanceof Type, with an optional Java 16+ pattern variable.InvokeDynamicExpr An invokedynamic call whose bootstrap method was not a recognized pattern, preserving the bootstrap information and call arguments for display.LambdaExpr A lambda expression: (params) -> body, whose body is either an Expression or a Statement block.LambdaParameter A lambda parameter with a name, a type, and whether the type is implicit in source.LiteralExpr A literal value: integers, floats, strings, booleans, chars, or null.MethodCallExpr A method call expression: obj.method(args) or Type.staticMethod(args).MethodRefExpr A method reference expression - Type::method, expr::method or Type::new.NewArrayExpr An array allocation - either sized by dimension expressions or by an initializer.NewExpr A constructor call expression - new Type(args), or outer.new Inner(args) when an enclosing instance is present.SuperExpr Represents the 'super' expression.SwitchExpr A switch expression (Java 14, JEP 361):switch (sel) { case L -> result; default -> r; }.SwitchExpr.Arm One arm.SwitchExpr.Component One component of a record-deconstruction pattern:type binding.TernaryExpr A conditional expression - condition ? thenExpr : elseExpr - whose three operands are children of this node.ThisExpr A reference to the enclosing instance - the 'this' expression.UnaryExpr Represents a unary expression: op operand (prefix) or operand op (postfix)VarRefExpr Represents a local variable reference. -
Enum Summary Enum Description BinaryOperator Binary operators for expressions.MethodRefKind Kinds of method references.UnaryOperator Unary operators for expressions.