public class ConstantExpression extends Expression
| Modifier and Type | Field and Description |
|---|---|
Object |
value |
nodeType, type| Constructor and Description |
|---|
ConstantExpression(Type type,
Object value) |
| Modifier and Type | Method and Description |
|---|---|
(package private) void |
accept(ExpressionWriter writer,
int lprec,
int rprec) |
Expression |
accept(Shuttle shuttle) |
<R> R |
accept(Visitor<R> visitor) |
private static boolean |
argsMatchFields(Field[] fields,
Class<?>[] parameterTypes) |
boolean |
equals(Object o) |
private static void |
escapeString(StringBuilder buf,
String s) |
Object |
evaluate(Evaluator evaluator) |
int |
hashCode() |
private static void |
list(ExpressionWriter writer,
List list,
String begin,
String sep,
String end) |
private static ExpressionWriter |
map(ExpressionWriter writer,
Map map,
String begin,
String entrySep,
String end) |
private static Constructor |
matchingConstructor(Object value) |
private static ExpressionWriter |
write(ExpressionWriter writer,
Object value,
Type type) |
private static ExpressionWriter |
writeMap(ExpressionWriter writer,
Map map) |
canReduceaccept, accept0, getNodeType, getType, toStringpublic final Object value
public Object evaluate(Evaluator evaluator)
evaluate in class AbstractNodepublic Expression accept(Shuttle shuttle)
accept in interface Nodeaccept in class Expressionpublic <R> R accept(Visitor<R> visitor)
void accept(ExpressionWriter writer, int lprec, int rprec)
accept in class AbstractNodeprivate static ExpressionWriter write(ExpressionWriter writer, Object value, Type type)
private static void list(ExpressionWriter writer, List list, String begin, String sep, String end)
private static ExpressionWriter writeMap(ExpressionWriter writer, Map map)
private static ExpressionWriter map(ExpressionWriter writer, Map map, String begin, String entrySep, String end)
private static Constructor matchingConstructor(Object value)
private static void escapeString(StringBuilder buf, String s)
public boolean equals(Object o)
equals in class AbstractNodepublic int hashCode()
hashCode in class AbstractNodeCopyright © 2012–2023 The Apache Software Foundation. All rights reserved.