org.weborganic.uri.template
Class VariableBinder
java.lang.Object
org.weborganic.uri.template.VariableBinder
public class VariableBinder
- extends Object
A convenience class is to bind variables to resolvers in a set of URI patterns.
- Version:
- 3 January 2009
- Author:
- Christophe Lauret
VariableBinder
public VariableBinder()
bind
public void bind(String name,
VariableResolver resolver)
- Binds the variables with the specified name to the specified resolver.
- Parameters:
name - The name of the variable.resolver - The resolver to use with these variables.
getResolver
public VariableResolver getResolver(String name)
- Returns the resolver used for the variable of the specified name.
This method does not return null. If the specified variable name is no bound
to any resolver the default resolver if returned instead.
- Parameters:
name - The name of the variables.
- Returns:
- the corresponding resolver.