Enum JexlUberspect.JexlResolver
- java.lang.Object
-
- java.lang.Enum<JexlUberspect.JexlResolver>
-
- org.apache.commons.jexl3.introspection.JexlUberspect.JexlResolver
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Comparable<JexlUberspect.JexlResolver>,JexlUberspect.PropertyResolver
- Enclosing interface:
- JexlUberspect
public static enum JexlUberspect.JexlResolver extends java.lang.Enum<JexlUberspect.JexlResolver> implements JexlUberspect.PropertyResolver
The various builtin property resolvers.Each resolver discovers how to set/get a property with different techniques; seeking method names or field names, etc.
- Since:
- 3.0
-
-
Enum Constant Summary
Enum Constants Enum Constant Description CONTAINERSeeks a getContainer(property) and setContainer(property, value) as inx.container.property.DUCKSeeks any get/{set,put} method (quacking like a list or a map).FIELDSeeks public instance members.LISTSeeks list methods to get/set.MAPSeeks map methods get/put.PROPERTYSeeks methods named get{P,p}property and is{P,p}property.
-
Constructor Summary
Constructors Modifier Constructor Description privateJexlResolver()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description JexlPropertyGetgetPropertyGet(JexlUberspect uber, java.lang.Object obj, java.lang.Object identifier)Gets a property getter.JexlPropertySetgetPropertySet(JexlUberspect uber, java.lang.Object obj, java.lang.Object identifier, java.lang.Object arg)Gets a property setter.static JexlUberspect.JexlResolvervalueOf(java.lang.String name)Returns the enum constant of this type with the specified name.static JexlUberspect.JexlResolver[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
PROPERTY
public static final JexlUberspect.JexlResolver PROPERTY
Seeks methods named get{P,p}property and is{P,p}property.
-
MAP
public static final JexlUberspect.JexlResolver MAP
Seeks map methods get/put.
-
LIST
public static final JexlUberspect.JexlResolver LIST
Seeks list methods to get/set.
-
DUCK
public static final JexlUberspect.JexlResolver DUCK
Seeks any get/{set,put} method (quacking like a list or a map).
-
FIELD
public static final JexlUberspect.JexlResolver FIELD
Seeks public instance members.
-
CONTAINER
public static final JexlUberspect.JexlResolver CONTAINER
Seeks a getContainer(property) and setContainer(property, value) as inx.container.property.
-
-
Method Detail
-
values
public static JexlUberspect.JexlResolver[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (JexlUberspect.JexlResolver c : JexlUberspect.JexlResolver.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static JexlUberspect.JexlResolver valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException- if this enum type has no constant with the specified namejava.lang.NullPointerException- if the argument is null
-
getPropertyGet
public final JexlPropertyGet getPropertyGet(JexlUberspect uber, java.lang.Object obj, java.lang.Object identifier)
Description copied from interface:JexlUberspect.PropertyResolverGets a property getter.- Specified by:
getPropertyGetin interfaceJexlUberspect.PropertyResolver- Parameters:
uber- the uberspectobj- the objectidentifier- the property identifier- Returns:
- the property getter or null
-
getPropertySet
public final JexlPropertySet getPropertySet(JexlUberspect uber, java.lang.Object obj, java.lang.Object identifier, java.lang.Object arg)
Description copied from interface:JexlUberspect.PropertyResolverGets a property setter.- Specified by:
getPropertySetin interfaceJexlUberspect.PropertyResolver- Parameters:
uber- the uberspectobj- the objectidentifier- the property identifierarg- the property value- Returns:
- the property setter or null
-
-