org.apache.myfaces.extensions.validator.core.metadata.extractor
Class DefaultComponentMetaDataExtractor

java.lang.Object
  extended by org.apache.myfaces.extensions.validator.core.metadata.extractor.DefaultComponentMetaDataExtractor
All Implemented Interfaces:
MetaDataExtractor

public class DefaultComponentMetaDataExtractor
extends Object
implements MetaDataExtractor

Default implementation which extracts meta-data (e.g. the annotations) of the value binding of a component. It extracts the meta-data of the field and the property. (Also the annotations of super classes and interfaces.)

Since:
1.x.1
Author:
Gerhard Petracek

Field Summary
protected  Logger logger
           
 
Constructor Summary
DefaultComponentMetaDataExtractor()
           
 
Method Summary
protected  void cacheMetaData(MetaDataStorage storage, PropertyInformation propertyInformation)
           
 PropertyInformation extract(javax.faces.context.FacesContext facesContext, Object object)
          Returns all information about the object.
protected  MetaDataEntry[] getCachedMetaData(MetaDataStorage storage, Class entityClass, String property)
           
protected  MetaDataStorage getMetaDataStorage()
           
protected  PropertyInformation getPropertyInformation(Class entityClass, PropertyDetails propertyDetails)
           
protected  boolean isCached(MetaDataStorage storage, Class entityClass, String property)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

logger

protected final Logger logger
Constructor Detail

DefaultComponentMetaDataExtractor

public DefaultComponentMetaDataExtractor()
Method Detail

extract

public PropertyInformation extract(javax.faces.context.FacesContext facesContext,
                                   Object object)
Description copied from interface: MetaDataExtractor
Returns all information about the object.

Specified by:
extract in interface MetaDataExtractor
Parameters:
facesContext - The JSF Faces Context
object - e.g. an instance of UIComponent which should be used to extract the information of the bound property.
Returns:
All the essential information about the bound property.

getPropertyInformation

protected PropertyInformation getPropertyInformation(Class entityClass,
                                                     PropertyDetails propertyDetails)

isCached

protected boolean isCached(MetaDataStorage storage,
                           Class entityClass,
                           String property)

cacheMetaData

protected void cacheMetaData(MetaDataStorage storage,
                             PropertyInformation propertyInformation)

getCachedMetaData

protected MetaDataEntry[] getCachedMetaData(MetaDataStorage storage,
                                            Class entityClass,
                                            String property)

getMetaDataStorage

protected MetaDataStorage getMetaDataStorage()


Copyright © 2008-2010 The Apache Software Foundation. All Rights Reserved.