| Modifier and Type | Class and Description |
|---|---|
| protected static class | Operator.
A descriptor comparison encapsulates the result of comparing descriptor for two operands and describes at what level they are compatible. |
| Modifier and Type | Field and Description |
|---|---|
| protected String | |
| private final String | |
| protected String |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public static boolean | equalityCheck(EvaluationContext
the current evaluation context context, Object the left-hand operand value left, Object the right-hand operand value right)Perform an equality check for the given operand values. |
| protected void | generateComparisonCode(MethodVisitor mv, CodeFlow cf, int compInstruction1, int compInstruction2)
Numeric comparison operators share very similar generated code, only differing in two comparison instructions. |
| public SpelNodeImpl | |
| public final String | |
| public SpelNodeImpl | |
| protected boolean | |
| public String | toStringAST()
Implements org. String format for all operators is the same
|
| leftActualDescriptor | back to summary |
|---|---|
| protected String leftActualDescriptor
| |
| operatorName | back to summary |
|---|---|
| private final String operatorName | |
| rightActualDescriptor | back to summary |
|---|---|
| protected String rightActualDescriptor
| |
| Operator | back to summary |
|---|---|
| public Operator(String payload, int startPos, int endPos, SpelNodeImpl... operands) | |
| equalityCheck | back to summary |
|---|---|
| public static boolean equalityCheck(EvaluationContext context, Object left, Object right) Perform an equality check for the given operand values. This method is not just used for reflective comparisons in subclasses
but also from compiled expression code, which is why it needs to be
declared as
| |
| generateComparisonCode | back to summary |
|---|---|
| protected void generateComparisonCode(MethodVisitor mv, CodeFlow cf, int compInstruction1, int compInstruction2) Numeric comparison operators share very similar generated code, only differing in two comparison instructions. | |
| getLeftOperand | back to summary |
|---|---|
| public SpelNodeImpl getLeftOperand() | |
| getOperatorName | back to summary |
|---|---|
| public final String getOperatorName() | |
| getRightOperand | back to summary |
|---|---|
| public SpelNodeImpl getRightOperand() | |
| isCompilableOperatorUsingNumerics | back to summary |
|---|---|
| protected boolean isCompilableOperatorUsingNumerics() | |
| toStringAST | back to summary |
|---|---|
| public String toStringAST() Implements org. String format for all operators is the same
| |
| Modifier and Type | Field and Description |
|---|---|
| pack-priv final boolean | |
| pack-priv final boolean | |
| pack-priv final char | |
| pack-priv static final Operator. | |
| pack-priv static final Operator. |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static Operator. | Returns: a DescriptorComparison object indicating the type of compatibility, if anythe statically determinable left descriptor leftDeclaredDescriptor, String the statically determinable right descriptor rightDeclaredDescriptor, String the dynamic/runtime left object descriptor leftActualDescriptor, String the dynamic/runtime right object descriptor rightActualDescriptor)Return an object that indicates whether the input descriptors are compatible. |
| areCompatible | back to summary |
|---|---|
| pack-priv final boolean areCompatible | |
| areNumbers | back to summary |
|---|---|
| pack-priv final boolean areNumbers | |
| compatibleType | back to summary |
|---|---|
| pack-priv final char compatibleType | |
| INCOMPATIBLE_NUMBERS | back to summary |
|---|---|
| pack-priv static final Operator. | |
| NOT_NUMBERS | back to summary |
|---|---|
| pack-priv static final Operator. | |
| DescriptorComparison | back to summary |
|---|---|
| private DescriptorComparison(boolean areNumbers, boolean areCompatible, char compatibleType) | |
| checkNumericCompatibility | back to summary |
|---|---|
| public static Operator. Return an object that indicates whether the input descriptors are compatible. A declared descriptor is what could statically be determined (e.g. from looking at the return value of a property accessor method) whilst an actual descriptor is the type of an actual object that was returned, which may differ. For generic types with unbound type variables, the declared descriptor discovered may be 'Object' but from the actual descriptor it is possible to observe that the objects are really numeric values (e.g. ints).
| |