Package org.zkoss.zkplus.cdi
Class DelegatingVariableResolver
- java.lang.Object
-
- org.zkoss.zkplus.cdi.DelegatingVariableResolver
-
- All Implemented Interfaces:
VariableResolver,VariableResolverX
public class DelegatingVariableResolver extends java.lang.Object implements VariableResolverX
Generic CDI EL named managed bean resolver.Applicable to CDI version 1.0 or later
- Author:
- henrichen
-
-
Constructor Summary
Constructors Constructor Description DelegatingVariableResolver()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object o)inthashCode()java.lang.ObjectresolveVariable(java.lang.String name)Resolves the specified variable.java.lang.ObjectresolveVariable(XelContext ctx, java.lang.Object base, java.lang.Object name)Resolves the the given variable on the given base object.
-
-
-
Method Detail
-
resolveVariable
public java.lang.Object resolveVariable(java.lang.String name) throws XelExceptionDescription copied from interface:VariableResolverResolves the specified variable.- Specified by:
resolveVariablein interfaceVariableResolver- Parameters:
name- the name of the variable to resolve- Throws:
XelException
-
resolveVariable
public java.lang.Object resolveVariable(XelContext ctx, java.lang.Object base, java.lang.Object name) throws XelException
Description copied from interface:VariableResolverXResolves the the given variable on the given base object.It resolves not only top-level variables but also properties. For example, when resolving
foo.duke,resolveVariable(ctx, null, "foo")is called first. And if it returns an non-null object,resolveVariable(ctx, foo, "duke")is called then (where we assume the returned object in the previous call isfoo).- Specified by:
resolveVariablein interfaceVariableResolverX- Parameters:
ctx- the context of this evaluationbase- the base object whose property value is to be returned, or null to resolve a top-level variable.name- the name of the variable (or property) to resolve- Throws:
XelException
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
-