org.springmodules.validation.bean.rule.resolver
Class StaticErrorArgumentsResolver

java.lang.Object
  extended by org.springmodules.validation.bean.rule.resolver.StaticErrorArgumentsResolver
All Implemented Interfaces:
ErrorArgumentsResolver

public class StaticErrorArgumentsResolver
extends Object
implements ErrorArgumentsResolver

An ErrorArgumentsResolver that is statically pre-configured with the error arguments, that is, the arguments are not dependent on the validated object.

Author:
Uri Boness

Constructor Summary
StaticErrorArgumentsResolver()
          Constructs a new StaticErrorArgumentsResolver with no arguments.
StaticErrorArgumentsResolver(Object[] arguments)
          Constructs a new StaticErrorArgumentsResolver with given static arguments.
 
Method Summary
 Object[] resolveArguments(Object obj)
          Returns the arguments that are configured in this resolver.
 void setArguments(Object[] arguments)
          Sets the static arguments to be returned by this resolver.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StaticErrorArgumentsResolver

public StaticErrorArgumentsResolver()
Constructs a new StaticErrorArgumentsResolver with no arguments.


StaticErrorArgumentsResolver

public StaticErrorArgumentsResolver(Object[] arguments)
Constructs a new StaticErrorArgumentsResolver with given static arguments.

Parameters:
arguments - The given static arguments.
Method Detail

resolveArguments

public Object[] resolveArguments(Object obj)
Returns the arguments that are configured in this resolver.

Specified by:
resolveArguments in interface ErrorArgumentsResolver
Parameters:
obj - The validated object.
Returns:
The validation error arguments.
See Also:
ErrorArgumentsResolver.resolveArguments(Object)

setArguments

public void setArguments(Object[] arguments)
Sets the static arguments to be returned by this resolver.

Parameters:
arguments - The static arguments to be returned by this resolver.


Copyright © 2009. All Rights Reserved.