org.apache.tapestry5.internal.services
Class DefaultDataTypeAnalyzer

java.lang.Object
  extended by org.apache.tapestry5.internal.services.DefaultDataTypeAnalyzer
All Implemented Interfaces:
DataTypeAnalyzer, InvalidationListener

public class DefaultDataTypeAnalyzer
extends Object
implements DataTypeAnalyzer, InvalidationListener

The default data type analyzer, which is based entirely on the type of the property (and not on annotations or naming conventions). This is based on a configuration of property type class to string provided as an IoC service configuration.


Constructor Summary
DefaultDataTypeAnalyzer(Map<Class,String> configuration)
           
 
Method Summary
 String identifyDataType(PropertyAdapter adapter)
          Identifies the data type, if known, or returns null if not known.
 void objectWasInvalidated()
          Clears the registry on an invalidation event (this is because the registry caches results, and the keys are classes that may be component classes from the invalidated component class loader).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultDataTypeAnalyzer

public DefaultDataTypeAnalyzer(Map<Class,String> configuration)
Method Detail

objectWasInvalidated

public void objectWasInvalidated()
Clears the registry on an invalidation event (this is because the registry caches results, and the keys are classes that may be component classes from the invalidated component class loader).

Specified by:
objectWasInvalidated in interface InvalidationListener

identifyDataType

public String identifyDataType(PropertyAdapter adapter)
Description copied from interface: DataTypeAnalyzer
Identifies the data type, if known, or returns null if not known.

Specified by:
identifyDataType in interface DataTypeAnalyzer


Copyright © 2003-2012 The Apache Software Foundation.