thinkmap.datasource.relational
Class EntityPropertyBinding<T>

java.lang.Object
  extended by thinkmap.datasource.relational.Binding<T>
      extended by thinkmap.datasource.relational.EntityPropertyBinding<T>
All Implemented Interfaces:
Serializable

public class EntityPropertyBinding<T>
extends Binding<T>

A binding to a value that is one of an Entity's properties.

Version:
$Revision: 1.9 $
See Also:
Serialized Form

Field Summary
protected  String propertyName
           
 
Constructor Summary
EntityPropertyBinding()
          Creates a new EntityPropertyBinding object.
 
Method Summary
 T bind(Message message, SourceEntity entity, EntityId id, Object ctx)
           
 String getPropertyName()
           
 void setPropertyName(String propertyName)
          Set the name of the property to retrieve from the entity.
 
Methods inherited from class thinkmap.datasource.relational.Binding
convertType, getOutputType, getProperty, getProperty, setOutputType, setProperty
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

propertyName

protected String propertyName
Constructor Detail

EntityPropertyBinding

public EntityPropertyBinding()
Creates a new EntityPropertyBinding object.

Method Detail

getPropertyName

public String getPropertyName()
Returns:
the name of the propert to retrieve from the entity.

setPropertyName

public void setPropertyName(String propertyName)
Set the name of the property to retrieve from the entity.

Parameters:
propertyName - the name of the property to retrieve from the entity.

bind

public T bind(Message message,
              SourceEntity entity,
              EntityId id,
              Object ctx)
       throws BindingException
Specified by:
bind in class Binding<T>
Parameters:
message - incoming message
entity - the entity being bound (may be null)
id - the id of the entity being bound
ctx - context object; datasource-specific
Returns:
value
Throws:
BindingException


Copyright © 2013 Thinkmap, Inc. All Rights Reserved.