org.pm4j.core.pm.impl.pathresolver
Class ExpressionPathResolver

java.lang.Object
  extended by org.pm4j.core.pm.impl.pathresolver.PathResolverBase
      extended by org.pm4j.core.pm.impl.pathresolver.ExpressionPathResolver
All Implemented Interfaces:
PathResolver

public class ExpressionPathResolver
extends PathResolverBase

Evaluates a path value based on an Expression implementation.

Author:
olaf boede

Constructor Summary
protected ExpressionPathResolver(Expression expression)
           
protected ExpressionPathResolver(java.lang.String exprString)
           
 
Method Summary
 java.lang.Object getValue(java.lang.Object startObj)
           
 java.lang.Object getValue(java.lang.Object pmCtxt, java.lang.Object startObj)
          Ignores the context parameter.
static PathResolver parse(java.lang.String exprString)
           
 void setValue(java.lang.Object startObj, java.lang.Object value)
           
 java.lang.String toString()
           
 
Methods inherited from class org.pm4j.core.pm.impl.pathresolver.PathResolverBase
isNullAllowed, setNullAllowed
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ExpressionPathResolver

protected ExpressionPathResolver(java.lang.String exprString)

ExpressionPathResolver

protected ExpressionPathResolver(Expression expression)
Method Detail

parse

public static PathResolver parse(java.lang.String exprString)

getValue

public java.lang.Object getValue(java.lang.Object startObj)
Parameters:
startObj - The object to start the navigation from.
Returns:
The found value according to the path specification.

getValue

public java.lang.Object getValue(java.lang.Object pmCtxt,
                                 java.lang.Object startObj)
Ignores the context parameter.

Parameters:
pmCtxt - The instance, used to create the execution context from.
Usually used to provide access to variables.
startObj - The instance to start the evaluation from.
Returns:
The evaluation result.

setValue

public void setValue(java.lang.Object startObj,
                     java.lang.Object value)
Parameters:
startObj - The object to start the navigation from.
value - The value to set to the field, addressed by the path.

toString

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