com.gridsystems.beanfilter
Class VariableValue

java.lang.Object
  extended by com.gridsystems.beanfilter.EvalValue
      extended by com.gridsystems.beanfilter.VariableValue

public class VariableValue
extends EvalValue

Name of the variable or the final field in a path.

  EX.1 :   module.parameter.name = "hello"
                            ^^^^
  EX.2 :   name = "John"
           ^^^^
 

Version:
1.0
Author:
Xmas

Field Summary
 
Fields inherited from class com.gridsystems.beanfilter.EvalValue
BOOLEAN, COLLECTION, NUMBER, STRING, UNKNOWN, VOID
 
Constructor Summary
VariableValue(Token token, java.lang.String s, java.lang.Class<?> parentClass)
          Creates a new instance.
 
Method Summary
 java.lang.Class<?> getClassValue(java.lang.Class<?> parentClass)
          
 java.lang.Object getValue(java.lang.Object parentValues)
          Gets the value.
 java.lang.String toString()
          
 
Methods inherited from class com.gridsystems.beanfilter.EvalValue
getCharPos, getLinePos
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

VariableValue

public VariableValue(Token token,
                     java.lang.String s,
                     java.lang.Class<?> parentClass)
              throws EvalException
Creates a new instance.

Parameters:
token - The token
s - The string
parentClass - Parent Class
Throws:
EvalException - If an error occurs
Method Detail

getValue

public java.lang.Object getValue(java.lang.Object parentValues)
                          throws EvalException
Gets the value.

Specified by:
getValue in class EvalValue
Parameters:
parentValues - The data source
Returns:
The value
Throws:
EvalException - FTR005: Unknown field path

toString

public java.lang.String toString()

Overrides:
toString in class java.lang.Object

getClassValue

public java.lang.Class<?> getClassValue(java.lang.Class<?> parentClass)
                                 throws EvalException

Specified by:
getClassValue in class EvalValue
Parameters:
parentClass - Parent Class
Returns:
Return the Java Class that represents or null if it is unknown.
Throws:
EvalException - If an error occurs


Copyright © 2007-2008 Grid Systems, S.A.. All Rights Reserved.