Interface JExpression

All Superinterfaces:
JGenerable
All Known Subinterfaces:
JAssignmentTarget
All Known Implementing Classes:
JArray, JArrayCompRef, JAssignment, JCast, JEnumConstant, JExpressionImpl, JFieldRef, JFieldVar, JInvocation, JStringLiteral, JVar

public interface JExpression extends JGenerable
A Java expression.

Unlike most of CodeModel, JExpressions are built bottom-up ( meaning you start from leaves and then gradually build compliated expressions by combining them.)

JExpression defines a series of composer methods, which returns a complicated expression (by often taking other JExpressions as parameters. For example, you can build "5+2" by JExpr.lit(5).add(JExpr.lit(2))