HHH-5709: New property added to PersistentClass to hold the name of the entity compliant with JSR-317 spec. Used by JPA2 metamodel.
This commit is contained in:
parent
b48c5b601c
commit
f29fab99a6
|
@ -195,6 +195,7 @@ public class EntityBinder {
|
|||
persistentClass.setAbstract( annotatedClass.isAbstract() );
|
||||
persistentClass.setClassName( annotatedClass.getName() );
|
||||
persistentClass.setNodeName( name );
|
||||
persistentClass.setAnnotatedEntityName(name);
|
||||
//persistentClass.setDynamic(false); //no longer needed with the Entity name refactoring?
|
||||
persistentClass.setEntityName( annotatedClass.getName() );
|
||||
bindDiscriminatorValue();
|
||||
|
|
|
@ -57,6 +57,7 @@ public abstract class PersistentClass implements Serializable, Filterable, MetaA
|
|||
private String proxyInterfaceName;
|
||||
|
||||
private String nodeName;
|
||||
private String annotatedEntityName;
|
||||
|
||||
private String discriminatorValue;
|
||||
private boolean lazy;
|
||||
|
@ -735,6 +736,14 @@ public abstract class PersistentClass implements Serializable, Filterable, MetaA
|
|||
public void setNodeName(String nodeName) {
|
||||
this.nodeName = nodeName;
|
||||
}
|
||||
|
||||
public String getAnnotatedEntityName() {
|
||||
return annotatedEntityName;
|
||||
}
|
||||
|
||||
public void setAnnotatedEntityName(String annotatedEntityName) {
|
||||
this.annotatedEntityName = annotatedEntityName;
|
||||
}
|
||||
|
||||
public boolean hasPojoRepresentation() {
|
||||
return getClassName()!=null;
|
||||
|
|
|
@ -94,7 +94,7 @@ public class MetamodelImpl implements Metamodel, Serializable {
|
|||
EntityTypeImpl entityType = new EntityTypeImpl(
|
||||
javaType,
|
||||
superType,
|
||||
persistentClass.getNodeName(),
|
||||
persistentClass.getAnnotatedEntityName(),
|
||||
persistentClass.hasIdentifierProperty(),
|
||||
persistentClass.isVersioned()
|
||||
);
|
||||
|
|
Loading…
Reference in New Issue