Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.tapestry5.internal.bindings
Class PropBinding

    java.lang.Object
      org.apache.tapestry5.ioc.BaseLocatable
          org.apache.tapestry5.internal.bindings.AbstractBinding
              org.apache.tapestry5.internal.bindings.PropBinding

All Implemented Interfaces:
  Binding, InternalPropBinding, AnnotationProvider, Locatable

    public class PropBinding

extends AbstractBinding
implements InternalPropBinding

Base class for bindings created by the `PropBindingFactory`. A subclass of this is created at runtime.

Constructor Summary
`PropBinding(Location location, java.lang.Object root, PropertyConduit conduit, java.lang.String expression, java.lang.String toString)`

Method Summary
`java.lang.Object` | `get()` The default implementation of get() will throw a TapestryException (binding is write only).
`
`<T extends java.lang.annotation.Annotation> T`
` | `getAnnotation(java.lang.Class<T> annotationClass)` Always returns null.
`java.lang.Class` | `getBindingType()` Returns the actual class, by invoking `Binding.get()`.
`java.lang.String` | `getExpression()`
`java.lang.String` | `getPropertyName()` Returns the name of the property, if exists.
`boolean` | `isInvariant()` Almost always returns false, unless the conduit provides the `Invariant` annotation.
`void` | `set(java.lang.Object value)` Updates the current value.
`java.lang.String` | `toString()`

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

### PropBinding

    public PropBinding(Location location,
                       java.lang.Object root,
                       PropertyConduit conduit,
                       java.lang.String expression,
                       java.lang.String toString)

Method Detail

### get

    public java.lang.Object get()

  The default implementation of get() will throw a TapestryException (binding is write only). The fabricated subclass may override this method (as well as set()).

  Specified by:
    `get` in interface `Binding`

### set

    public void set(java.lang.Object value)

  Description copied from interface: `Binding`
  Updates the current value. Most types of bindings are read-only, and this method will throw a runtime exception. It is the caller's responsibility to ensure that the value passed in is of the appropriate type.

  Specified by:
    `set` in interface `Binding`
  Overrides:
    `set` in class `AbstractBinding`

### toString

    public java.lang.String toString()

  Overrides:
    `toString` in class `java.lang.Object`

### isInvariant

    public boolean isInvariant()

  Almost always returns false, unless the conduit provides the `Invariant` annotation.

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

### getBindingType

    public java.lang.Class getBindingType()

  Description copied from class: `AbstractBinding`
  Returns the actual class, by invoking `Binding.get()`. Subclasses may override this method to work more efficiently (say, when the binding type is known statically).

  Specified by:
    `getBindingType` in interface `Binding`
  Overrides:
    `getBindingType` in class `AbstractBinding`

### getAnnotation

    public <T extends java.lang.annotation.Annotation> T getAnnotation(java.lang.Class<T> annotationClass)

  Description copied from class: `AbstractBinding`
  Always returns null. Bindings that provide access to a method or field will override this method to return the appropriate annotation.

  Specified by:
    `getAnnotation` in interface `AnnotationProvider`
  Overrides:
    `getAnnotation` in class `AbstractBinding`
  Parameters:
    `annotationClass` - used to select the annotation to return
  Returns:
    the annotation, or null if not found

### getPropertyName

    public java.lang.String getPropertyName()

  Description copied from interface: `InternalPropBinding`
  Returns the name of the property, if exists.

  Specified by:
    `getPropertyName` in interface `InternalPropBinding`

### getExpression

    public java.lang.String getExpression()

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2003-2012 The Apache Software Foundation.