org.mvel2.integration.impl
Class TypeInjectionResolverFactoryImpl

java.lang.Object
  extended by org.mvel2.integration.impl.BaseVariableResolverFactory
      extended by org.mvel2.integration.impl.MapVariableResolverFactory
          extended by org.mvel2.integration.impl.TypeInjectionResolverFactoryImpl
All Implemented Interfaces:
java.io.Serializable, TypeInjectionResolverFactory, VariableResolverFactory

public class TypeInjectionResolverFactoryImpl
extends MapVariableResolverFactory
implements TypeInjectionResolverFactory

See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.mvel2.integration.impl.MapVariableResolverFactory
variables
 
Fields inherited from class org.mvel2.integration.impl.BaseVariableResolverFactory
indexedVariableNames, indexedVariableResolvers, indexOffset, nextFactory, variableResolvers
 
Constructor Summary
TypeInjectionResolverFactoryImpl()
           
TypeInjectionResolverFactoryImpl(java.util.Map<java.lang.String,java.lang.Object> variables)
           
TypeInjectionResolverFactoryImpl(java.util.Map<java.lang.String,java.lang.Object> variables, boolean cachingSafe)
           
TypeInjectionResolverFactoryImpl(java.util.Map<java.lang.String,java.lang.Object> variables, VariableResolverFactory nextFactory)
           
TypeInjectionResolverFactoryImpl(ParserContext ctx, VariableResolverFactory nextVariableResolverFactory)
           
 
Method Summary
 VariableResolver createVariable(java.lang.String name, java.lang.Object value)
          Creates a new variable.
 VariableResolver createVariable(java.lang.String name, java.lang.Object value, java.lang.Class<?> type)
          Creates a new variable, and assigns a static type.
 java.util.Set<java.lang.String> getKnownVariables()
          Return a list of known variables inside the factory.
 
Methods inherited from class org.mvel2.integration.impl.MapVariableResolverFactory
addResolver, clear, getVariableResolver, isResolveable, isTarget
 
Methods inherited from class org.mvel2.integration.impl.BaseVariableResolverFactory
appendFactory, createIndexedVariable, createIndexedVariable, getIndexedVariableNames, getIndexedVariableResolver, getNextFactory, getVariableResolvers, insertFactory, isIndexedFactory, isNextResolveable, setIndexedVariableNames, setIndexedVariableResolver, setNextFactory, setVariableResolvers, variableIndexOf
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TypeInjectionResolverFactoryImpl

public TypeInjectionResolverFactoryImpl()

TypeInjectionResolverFactoryImpl

public TypeInjectionResolverFactoryImpl(java.util.Map<java.lang.String,java.lang.Object> variables)

TypeInjectionResolverFactoryImpl

public TypeInjectionResolverFactoryImpl(ParserContext ctx,
                                        VariableResolverFactory nextVariableResolverFactory)

TypeInjectionResolverFactoryImpl

public TypeInjectionResolverFactoryImpl(java.util.Map<java.lang.String,java.lang.Object> variables,
                                        VariableResolverFactory nextFactory)

TypeInjectionResolverFactoryImpl

public TypeInjectionResolverFactoryImpl(java.util.Map<java.lang.String,java.lang.Object> variables,
                                        boolean cachingSafe)
Method Detail

createVariable

public VariableResolver createVariable(java.lang.String name,
                                       java.lang.Object value)
Description copied from interface: VariableResolverFactory
Creates a new variable. This probably doesn't need to be implemented in most scenarios. This is used for variable assignment.

Specified by:
createVariable in interface VariableResolverFactory
Overrides:
createVariable in class MapVariableResolverFactory
Parameters:
name - - name of the variable being created
value - - value of the variable
Returns:
instance of the variable resolver associated with the variable

createVariable

public VariableResolver createVariable(java.lang.String name,
                                       java.lang.Object value,
                                       java.lang.Class<?> type)
Description copied from interface: VariableResolverFactory
Creates a new variable, and assigns a static type. It is expected the underlying factory and resolver will enforce this.

Specified by:
createVariable in interface VariableResolverFactory
Overrides:
createVariable in class MapVariableResolverFactory
Parameters:
name - - name of the variable being created
value - - value of the variable
type - - the static type
Returns:
instance of the variable resolver associated with the variable

getKnownVariables

public java.util.Set<java.lang.String> getKnownVariables()
Description copied from interface: VariableResolverFactory
Return a list of known variables inside the factory. This method should not recurse into other factories. But rather return only the variables living inside this factory.

Specified by:
getKnownVariables in interface VariableResolverFactory
Overrides:
getKnownVariables in class MapVariableResolverFactory
Returns:


Copyright © 2010. All Rights Reserved.