org.hibernate.cfg
Class AnnotationBinder

java.lang.Object
  extended by org.hibernate.cfg.AnnotationBinder

public final class AnnotationBinder
extends Object

JSR 175 annotation binder Will read the annotation from classes, apply the principles of the EJB3 spec and produces the Hibernate configuration-time metamodel (the classes in the mapping package)

Author:
Emmanuel Bernard

Field Summary
static String ANNOTATION_STRING_DEFAULT
           
 
Method Summary
static void bindClass(XClass clazzToProcess, Map<XClass,InheritanceState> inheritanceStatePerClass, ExtendedMappings mappings)
          Bind a class having JSR175 annotations The subclasses have to be binded after its mother class
static void bindDefaults(ExtendedMappings mappings)
           
static void bindPackage(String packageName, ExtendedMappings mappings)
           
static Map<XClass,InheritanceState> buildInheritanceStates(List<XClass> orderedClasses, ReflectionManager reflectionManager)
           
protected static void defineFetchingStrategy(org.hibernate.mapping.ToOne toOne, XProperty property)
           
static org.hibernate.mapping.Component fillComponent(PropertyHolder propertyHolder, PropertyData inferredData, boolean propertyAnnotated, String propertyAccessor, boolean isNullable, EntityBinder entityBinder, boolean isComponentEmbedded, boolean isIdentifierMapper, ExtendedMappings mappings)
           
static org.hibernate.FetchMode getFetchMode(javax.persistence.FetchType fetch)
           
static boolean isDefault(String annotationString)
           
static boolean isDefault(XClass clazz, ExtendedMappings mappings)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ANNOTATION_STRING_DEFAULT

public static final String ANNOTATION_STRING_DEFAULT
See Also:
Constant Field Values
Method Detail

bindDefaults

public static void bindDefaults(ExtendedMappings mappings)

bindPackage

public static void bindPackage(String packageName,
                               ExtendedMappings mappings)

bindClass

public static void bindClass(XClass clazzToProcess,
                             Map<XClass,InheritanceState> inheritanceStatePerClass,
                             ExtendedMappings mappings)
                      throws org.hibernate.MappingException
Bind a class having JSR175 annotations The subclasses have to be binded after its mother class

Throws:
org.hibernate.MappingException

fillComponent

public static org.hibernate.mapping.Component fillComponent(PropertyHolder propertyHolder,
                                                            PropertyData inferredData,
                                                            boolean propertyAnnotated,
                                                            String propertyAccessor,
                                                            boolean isNullable,
                                                            EntityBinder entityBinder,
                                                            boolean isComponentEmbedded,
                                                            boolean isIdentifierMapper,
                                                            ExtendedMappings mappings)

defineFetchingStrategy

protected static void defineFetchingStrategy(org.hibernate.mapping.ToOne toOne,
                                             XProperty property)

getFetchMode

public static org.hibernate.FetchMode getFetchMode(javax.persistence.FetchType fetch)

isDefault

public static boolean isDefault(String annotationString)

isDefault

public static boolean isDefault(XClass clazz,
                                ExtendedMappings mappings)

buildInheritanceStates

public static Map<XClass,InheritanceState> buildInheritanceStates(List<XClass> orderedClasses,
                                                                  ReflectionManager reflectionManager)