org.hibernate.tool.hbm2x.pojo
Class EntityPOJOClass

java.lang.Object
  extended by org.hibernate.tool.hbm2x.pojo.BasicPOJOClass
      extended by org.hibernate.tool.hbm2x.pojo.EntityPOJOClass
All Implemented Interfaces:
MetaAttributeConstants, ImportContext, POJOClass

public class EntityPOJOClass
extends BasicPOJOClass


Nested Class Summary
static class EntityPOJOClass.IteratorTransformer
           
 
Field Summary
 
Fields inherited from class org.hibernate.tool.hbm2x.pojo.BasicPOJOClass
c2j, importContext, meta
 
Fields inherited from interface org.hibernate.tool.hbm2x.MetaAttributeConstants
CLASS_DESCRIPTION, CLASS_MODIFIER, EXTENDS, GEN_PROPERTY, GENERATED_CLASS, IMPLEMENTS, INTERFACE, SCOPE_CLASS
 
Constructor Summary
EntityPOJOClass(org.hibernate.mapping.PersistentClass clazz, Cfg2JavaTool cfg)
           
 
Method Summary
 String generateAnnIdGenerator()
           
 String generateAnnTableUniqueConstraint()
           
protected  String generateAnnTableUniqueConstraint(org.hibernate.mapping.Table table)
           
 String generateCollectionAnnotation(org.hibernate.mapping.Property property, org.hibernate.cfg.Configuration cfg)
           
 String generateJoinColumnsAnnotation(org.hibernate.mapping.Property property, org.hibernate.cfg.Configuration cfg)
           
 String generateManyToOneAnnotation(org.hibernate.mapping.Property property)
           
 Iterator getAllPropertiesIterator()
          returns the properties that would be visible on this entity as a pojo.
 Iterator getAllPropertiesIterator(org.hibernate.mapping.PersistentClass pc)
           
 String[] getCascadeTypes(org.hibernate.mapping.Property property)
           
 Object getDecoratedObject()
           
 String getExtends()
           
 String getFetchType(org.hibernate.mapping.Property property)
           
 String getHibernateCascadeTypeAnnotation(org.hibernate.mapping.Property property)
           
 org.hibernate.mapping.Property getIdentifierProperty()
           
 String getImplements()
           
protected  String getMappedClassName()
           
 List getPropertiesForFullConstructor()
           
protected  List getPropertiesForFullConstructor(org.hibernate.mapping.PersistentClass pc)
           
 List getPropertiesForMinimalConstructor()
           
protected  List getPropertiesForMinimalConstructor(org.hibernate.mapping.PersistentClass pc)
           
 List getPropertyClosureForFullConstructor()
           
protected  List getPropertyClosureForFullConstructor(org.hibernate.mapping.PersistentClass pc)
           
 List getPropertyClosureForMinimalConstructor()
           
protected  List getPropertyClosureForMinimalConstructor(org.hibernate.mapping.PersistentClass pc)
           
 List getPropertyClosureForSuperclassFullConstructor()
           
 List getPropertyClosureForSuperclassFullConstructor(org.hibernate.mapping.PersistentClass pc)
           
protected  List getPropertyClosureForSuperclassMinConstructor(org.hibernate.mapping.PersistentClass pc)
           
 List getPropertyClosureForSuperclassMinimalConstructor()
           
 POJOClass getSuperClass()
           
 org.hibernate.mapping.Property getVersionProperty()
           
 boolean hasIdentifierProperty()
           
 boolean hasVersionProperty()
           
protected  boolean isAssignedIdentifier(org.hibernate.mapping.PersistentClass pc, org.hibernate.mapping.Property property)
           
 boolean isComponent()
           
 boolean isSubclass()
           
 String toString()
           
 
Methods inherited from class org.hibernate.tool.hbm2x.pojo.BasicPOJOClass
appendCommonColumnInfo, beanCapitalize, generateAnnColumnAnnotation, generateBasicAnnotation, generateEquals, generateEquals, generateHashCode, generateImports, getClassJavaDoc, getClassModifiers, getCollectionNameFor, getDeclarationName, getDeclarationType, getEqualsHashCodePropertiesIterator, getExtendsDeclaration, getExtraClassCode, getFieldDescription, getFieldInitialization, getFieldJavaDoc, getFieldModifiers, getGeneratedClassName, getGetterSignature, getImplementsDeclaration, getJavaTypeName, getMetaAsBool, getMetaAsBool, getMetaAsString, getMetaAsString, getMetaAttribAsBool, getPackageDeclaration, getPackageDeclaration, getPackageName, getPropertyGetModifiers, getPropertyName, getPropertySetModifiers, getQualifiedDeclarationName, getShortName, getToStringPropertiesIterator, hasFieldInitializor, hasFieldJavaDoc, hasMetaAttribute, hasMetaAttribute, importType, init, isComponent, isInterface, isRequiredInConstructor, needsEqualsHashCode, needsFullConstructor, needsMinimalConstructor, needsToString, qualifyInnerClass, staticImport
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

EntityPOJOClass

public EntityPOJOClass(org.hibernate.mapping.PersistentClass clazz,
                       Cfg2JavaTool cfg)
Method Detail

getMappedClassName

protected String getMappedClassName()
Specified by:
getMappedClassName in class BasicPOJOClass

getExtends

public String getExtends()
Specified by:
getExtends in interface POJOClass
Specified by:
getExtends in class BasicPOJOClass
Returns:
whatever the class (or interface) extends (null if it does not extend anything)

getImplements

public String getImplements()
Specified by:
getImplements in interface POJOClass
Specified by:
getImplements in class BasicPOJOClass

getAllPropertiesIterator

public Iterator getAllPropertiesIterator()
Description copied from class: BasicPOJOClass
returns the properties that would be visible on this entity as a pojo. This does not return *all* properties since hibernate has certain properties that are only relevant in context of persistence.

Specified by:
getAllPropertiesIterator in interface POJOClass
Specified by:
getAllPropertiesIterator in class BasicPOJOClass

getAllPropertiesIterator

public Iterator getAllPropertiesIterator(org.hibernate.mapping.PersistentClass pc)

isComponent

public boolean isComponent()

hasIdentifierProperty

public boolean hasIdentifierProperty()

getIdentifierProperty

public org.hibernate.mapping.Property getIdentifierProperty()

generateAnnTableUniqueConstraint

public String generateAnnTableUniqueConstraint()

generateAnnTableUniqueConstraint

protected String generateAnnTableUniqueConstraint(org.hibernate.mapping.Table table)

generateAnnIdGenerator

public String generateAnnIdGenerator()

generateJoinColumnsAnnotation

public String generateJoinColumnsAnnotation(org.hibernate.mapping.Property property,
                                            org.hibernate.cfg.Configuration cfg)

getCascadeTypes

public String[] getCascadeTypes(org.hibernate.mapping.Property property)

generateManyToOneAnnotation

public String generateManyToOneAnnotation(org.hibernate.mapping.Property property)

getHibernateCascadeTypeAnnotation

public String getHibernateCascadeTypeAnnotation(org.hibernate.mapping.Property property)

getFetchType

public String getFetchType(org.hibernate.mapping.Property property)

getDecoratedObject

public Object getDecoratedObject()

generateCollectionAnnotation

public String generateCollectionAnnotation(org.hibernate.mapping.Property property,
                                           org.hibernate.cfg.Configuration cfg)

isSubclass

public boolean isSubclass()

getPropertyClosureForFullConstructor

public List getPropertyClosureForFullConstructor()

getPropertyClosureForFullConstructor

protected List getPropertyClosureForFullConstructor(org.hibernate.mapping.PersistentClass pc)

getPropertiesForFullConstructor

public List getPropertiesForFullConstructor()

getPropertiesForFullConstructor

protected List getPropertiesForFullConstructor(org.hibernate.mapping.PersistentClass pc)

getPropertyClosureForSuperclassFullConstructor

public List getPropertyClosureForSuperclassFullConstructor()

getPropertyClosureForSuperclassFullConstructor

public List getPropertyClosureForSuperclassFullConstructor(org.hibernate.mapping.PersistentClass pc)

getPropertyClosureForMinimalConstructor

public List getPropertyClosureForMinimalConstructor()

getPropertyClosureForMinimalConstructor

protected List getPropertyClosureForMinimalConstructor(org.hibernate.mapping.PersistentClass pc)

getPropertiesForMinimalConstructor

public List getPropertiesForMinimalConstructor()

getPropertiesForMinimalConstructor

protected List getPropertiesForMinimalConstructor(org.hibernate.mapping.PersistentClass pc)

isAssignedIdentifier

protected boolean isAssignedIdentifier(org.hibernate.mapping.PersistentClass pc,
                                       org.hibernate.mapping.Property property)

getPropertyClosureForSuperclassMinimalConstructor

public List getPropertyClosureForSuperclassMinimalConstructor()

getPropertyClosureForSuperclassMinConstructor

protected List getPropertyClosureForSuperclassMinConstructor(org.hibernate.mapping.PersistentClass pc)

getSuperClass

public POJOClass getSuperClass()

toString

public String toString()
Overrides:
toString in class Object

hasVersionProperty

public boolean hasVersionProperty()

getVersionProperty

public org.hibernate.mapping.Property getVersionProperty()