public class Checker extends Object
Constructor and Description |
---|
Checker() |
Modifier and Type | Method and Description |
---|---|
static Object |
checkedBinaryOp(Object lhs,
int op,
Object rhs)
Intercepts the binary expression of the form "lhs op rhs" like "lhs+rhs", "lhs>>rhs", etc.
|
static Object |
checkedCall(Object _receiver,
boolean safe,
boolean spread,
String _method,
Object[] _args) |
static Object |
checkedComparison(Object lhs,
int op,
Object rhs)
A compare method that invokes a.equals(b) or a.compareTo(b)==0
|
static Object |
checkedConstructor(Class _type,
Object[] _args) |
static Object |
checkedGetArray(Object _receiver,
Object _index) |
static Object |
checkedGetAttribute(Object _receiver,
boolean safe,
boolean spread,
Object _property) |
static Object |
checkedGetProperty(Object _receiver,
boolean safe,
boolean spread,
Object _property) |
static Object |
checkedPostfixArray(Object r,
Object i,
String op)
a[i]++ / a[i]--
|
static Object |
checkedPostfixProperty(Object receiver,
Object property,
boolean safe,
boolean spread,
String op)
a.x++ / a.x--
|
static Object |
checkedPrefixArray(Object r,
Object i,
String op)
++a[i] / --a[i]
|
static Object |
checkedPrefixProperty(Object receiver,
Object property,
boolean safe,
boolean spread,
String op)
++a.x / --a.x
|
static Object |
checkedSetArray(Object _receiver,
Object _index,
int op,
Object _value)
Intercepts the array assignment of the form "receiver[index] = value"
|
static Object |
checkedSetAttribute(Object _receiver,
Object _property,
boolean safe,
boolean spread,
int op,
Object _value)
Intercepts the attribute assignment of the form "receiver.@property = value"
|
static Object |
checkedSetProperty(Object _receiver,
Object _property,
boolean safe,
boolean spread,
int op,
Object _value) |
static Object |
checkedStaticCall(Class _receiver,
String _method,
Object[] _args) |
public static Object checkedCall(Object _receiver, boolean safe, boolean spread, String _method, Object[] _args) throws Throwable
Throwable
public static Object checkedStaticCall(Class _receiver, String _method, Object[] _args) throws Throwable
Throwable
public static Object checkedConstructor(Class _type, Object[] _args) throws Throwable
Throwable
public static Object checkedGetProperty(Object _receiver, boolean safe, boolean spread, Object _property) throws Throwable
Throwable
public static Object checkedSetProperty(Object _receiver, Object _property, boolean safe, boolean spread, int op, Object _value) throws Throwable
Throwable
public static Object checkedGetAttribute(Object _receiver, boolean safe, boolean spread, Object _property) throws Throwable
Throwable
public static Object checkedSetAttribute(Object _receiver, Object _property, boolean safe, boolean spread, int op, Object _value) throws Throwable
op
- One of the assignment operators of Types
Throwable
public static Object checkedGetArray(Object _receiver, Object _index) throws Throwable
Throwable
public static Object checkedSetArray(Object _receiver, Object _index, int op, Object _value) throws Throwable
op
- One of the assignment operators of Types
Throwable
public static Object checkedPostfixArray(Object r, Object i, String op) throws Throwable
op
- "next" for ++, "previous" for --. These names are defined by Groovy.Throwable
public static Object checkedPrefixArray(Object r, Object i, String op) throws Throwable
Throwable
public static Object checkedPostfixProperty(Object receiver, Object property, boolean safe, boolean spread, String op) throws Throwable
Throwable
public static Object checkedPrefixProperty(Object receiver, Object property, boolean safe, boolean spread, String op) throws Throwable
Throwable
public static Object checkedBinaryOp(Object lhs, int op, Object rhs) throws Throwable
op
- One of the binary operators of Types
Throwable
BinaryExpressionHelper.evaluateBinaryExpressionWithAssignment(java.lang.String, org.codehaus.groovy.ast.expr.BinaryExpression)
Copyright © 2015. All rights reserved.