org.chenillekit.tapestry.core.bindings
Class OgnlBinding

java.lang.Object
  extended by org.apache.tapestry5.ioc.BaseLocatable
      extended by org.apache.tapestry5.internal.bindings.AbstractBinding
          extended by org.chenillekit.tapestry.core.bindings.OgnlBinding
All Implemented Interfaces:
Binding, AnnotationProvider, Locatable

public class OgnlBinding
extends AbstractBinding

Binding type for OGNL expressions. This binding called by expression "ognl:".

Version:
$Id: OgnlBinding.java 594 2009-12-05 15:17:26Z mlusetti $

Constructor Summary
OgnlBinding(Location location, Object root, String expression)
           
 
Method Summary
 Object get()
          Reads the current value of the property (or other resource).
 Object getParsedExpression(String expression)
          Gets a parsed OGNL expression from the input string.
 boolean isInvariant()
          Returns false; these properties are always dynamic.
 String toString()
           
 
Methods inherited from class org.apache.tapestry5.internal.bindings.AbstractBinding
getAnnotation, getBindingType, set
 
Methods inherited from class org.apache.tapestry5.ioc.BaseLocatable
getLocation
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

OgnlBinding

public OgnlBinding(Location location,
                   Object root,
                   String expression)
Method Detail

getParsedExpression

public Object getParsedExpression(String expression)
Gets a parsed OGNL expression from the input string.

Throws:
TapestryException - if the expression can not be parsed.

get

public Object get()
Reads the current value of the property (or other resource). When reading properties of objects that are primitive types, this will return an instance of the wrapper type. In some cases, a binding is read only and this method will throw a runtime exception.


isInvariant

public boolean isInvariant()
Returns false; these properties are always dynamic.

Specified by:
isInvariant in interface Binding
Overrides:
isInvariant in class AbstractBinding

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2008-2011 ChenilleKit. All Rights Reserved.