public class LinkingUberspector extends AbstractChainableUberspector
When the runtime.introspection.uberspect configuration property contains several uberspector class names, it means those uberspectors will be chained. When an uberspector in the list other than the leftmost does not implement ChainableUberspector, then this utility class is used to provide a basic default chaining where the first non-null result is kept for each introspection call.
ChainableUberspectorUberspectImpl.VelGetterImpl, UberspectImpl.VelMethodImpl, UberspectImpl.VelSetterImplinnerintrospector, log| Constructor and Description |
|---|
LinkingUberspector(Uberspect left,
Uberspect right)
Constructor that takes the two uberspectors to link
|
| Modifier and Type | Method and Description |
|---|---|
java.util.Iterator |
getIterator(java.lang.Object obj,
Info i)
To support iterative objects used in a
#foreach()
loop. |
VelMethod |
getMethod(java.lang.Object obj,
java.lang.String methodName,
java.lang.Object[] args,
Info i)
Method
|
VelPropertyGet |
getPropertyGet(java.lang.Object obj,
java.lang.String identifier,
Info i)
Property getter
|
VelPropertySet |
getPropertySet(java.lang.Object obj,
java.lang.String identifier,
java.lang.Object arg,
Info i)
Property setter
|
void |
init()
init - the chainable uberspector is responsible for the initialization of the wrapped uberspector
|
wrapsetLog, setRuntimeLoggerpublic void init()
Init both wrapped uberspectors
init in interface Uberspectinit in class AbstractChainableUberspectorUberspect.init()public java.util.Iterator getIterator(java.lang.Object obj,
Info i)
throws java.lang.Exception
#foreach()
loop.getIterator in interface UberspectgetIterator in class AbstractChainableUberspectorobj - The iterative object.i - Info about the object's location.Iterator object.java.lang.ExceptionUberspect.getIterator(java.lang.Object,
bboss.org.apache.velocity.util.introspection.Info)public VelMethod getMethod(java.lang.Object obj, java.lang.String methodName, java.lang.Object[] args, Info i) throws java.lang.Exception
getMethod in interface UberspectgetMethod in class AbstractChainableUberspectorjava.lang.ExceptionUberspect.getMethod(java.lang.Object, java.lang.String,
java.lang.Object[], bboss.org.apache.velocity.util.introspection.Info)public VelPropertyGet getPropertyGet(java.lang.Object obj, java.lang.String identifier, Info i) throws java.lang.Exception
getPropertyGet in interface UberspectgetPropertyGet in class AbstractChainableUberspectorjava.lang.ExceptionUberspect.getPropertyGet(java.lang.Object, java.lang.String,
bboss.org.apache.velocity.util.introspection.Info)public VelPropertySet getPropertySet(java.lang.Object obj, java.lang.String identifier, java.lang.Object arg, Info i) throws java.lang.Exception
getPropertySet in interface UberspectgetPropertySet in class AbstractChainableUberspectorjava.lang.ExceptionUberspect.getPropertySet(java.lang.Object, java.lang.String,
java.lang.Object, bboss.org.apache.velocity.util.introspection.Info)