org.ow2.util.substitution.resolver
Class ChainedResolver

java.lang.Object
  extended by org.ow2.util.substitution.resolver.ChainedResolver
All Implemented Interfaces:
IPropertyResolver

public class ChainedResolver
extends Object
implements IPropertyResolver

Manage a List of IPropertyResolver. During resolution, the first non-null value returned by a resolver is used. Order is the one of the resolvers List.

Author:
Guillaume Sauthier

Constructor Summary
ChainedResolver()
           
 
Method Summary
 List<IPropertyResolver> getResolvers()
           
 String resolve(String expression)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ChainedResolver

public ChainedResolver()
Method Detail

getResolvers

public List<IPropertyResolver> getResolvers()

resolve

public String resolve(String expression)
Specified by:
resolve in interface IPropertyResolver
Parameters:
expression - a property name
Returns:
the value related to the expression, or null if not found.


Copyright © 2007-2012 OW2 Consortium. All Rights Reserved.