com.caucho.el
Class MapVariableResolver

java.lang.Object
  extended by javax.el.ELResolver
      extended by com.caucho.el.MapVariableResolver

public class MapVariableResolver
extends ELResolver

Variable resolver using an underlying Map.


Field Summary
 
Fields inherited from class javax.el.ELResolver
RESOLVABLE_AT_DESIGN_TIME, TYPE
 
Constructor Summary
MapVariableResolver()
          Creates the resolver
MapVariableResolver(java.util.Map<java.lang.String,java.lang.Object> map)
          Creates the resolver
 
Method Summary
 java.lang.Class<?> getCommonPropertyType(ELContext context, java.lang.Object base)
           
 java.util.Iterator<java.beans.FeatureDescriptor> getFeatureDescriptors(ELContext context, java.lang.Object base)
           
 java.util.Map<java.lang.String,java.lang.Object> getMap()
          Gets the map.
 java.lang.Class<?> getType(ELContext context, java.lang.Object base, java.lang.Object property)
          Returns the named variable value.
 java.lang.Object getValue(ELContext context, java.lang.Object base, java.lang.Object property)
          Returns the named variable value.
 boolean isReadOnly(ELContext context, java.lang.Object base, java.lang.Object property)
          Returns true for read-only.
 java.lang.Object put(java.lang.String var, java.lang.Object value)
          Sets the named variable value.
 void setMap(java.util.Map<java.lang.String,java.lang.Object> map)
          Sets the map.
 void setValue(ELContext context, java.lang.Object base, java.lang.Object property, java.lang.Object value)
          Returns the named variable value.
 java.lang.String toString()
           
 
Methods inherited from class javax.el.ELResolver
invoke
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MapVariableResolver

public MapVariableResolver(java.util.Map<java.lang.String,java.lang.Object> map)
Creates the resolver


MapVariableResolver

public MapVariableResolver()
Creates the resolver

Method Detail

getValue

public java.lang.Object getValue(ELContext context,
                                 java.lang.Object base,
                                 java.lang.Object property)
Returns the named variable value.

Specified by:
getValue in class ELResolver

setValue

public void setValue(ELContext context,
                     java.lang.Object base,
                     java.lang.Object property,
                     java.lang.Object value)
Returns the named variable value.

Specified by:
setValue in class ELResolver

put

public java.lang.Object put(java.lang.String var,
                            java.lang.Object value)
Sets the named variable value.


isReadOnly

public boolean isReadOnly(ELContext context,
                          java.lang.Object base,
                          java.lang.Object property)
Returns true for read-only.

Specified by:
isReadOnly in class ELResolver

getType

public java.lang.Class<?> getType(ELContext context,
                                  java.lang.Object base,
                                  java.lang.Object property)
Returns the named variable value.

Specified by:
getType in class ELResolver

getCommonPropertyType

public java.lang.Class<?> getCommonPropertyType(ELContext context,
                                                java.lang.Object base)
Specified by:
getCommonPropertyType in class ELResolver

getFeatureDescriptors

public java.util.Iterator<java.beans.FeatureDescriptor> getFeatureDescriptors(ELContext context,
                                                                              java.lang.Object base)
Specified by:
getFeatureDescriptors in class ELResolver

getMap

public java.util.Map<java.lang.String,java.lang.Object> getMap()
Gets the map.


setMap

public void setMap(java.util.Map<java.lang.String,java.lang.Object> map)
Sets the map.


toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object