private void bindUnionSubclassEntity(
SubclassEntitySourceImpl entitySource,
UnionSubclass entityDescriptor) {
MappingDocument mappingDocument = entitySource.sourceMappingDocument();
bindBasicEntityValues(
mappingDocument,
entitySource,
entityDescriptor
);
final MappedTable primaryTable = bindEntityTableSpecification(
mappingDocument,
entitySource.getPrimaryTable(),
entityDescriptor.getSuperManagedTypeMapping().getMappedTable(),
entitySource,
entityDescriptor
);
entityDescriptor.setMappedTable( primaryTable );
if ( log.isDebugEnabled() ) {
log.debugf( "Mapping union-subclass: %s -> %s", entityDescriptor.getEntityName(), primaryTable.getName() );
}
bindAllEntityAttributes(
entitySource.sourceMappingDocument(),
entitySource,
entityDescriptor
);
bindUnionSubclassEntities( entitySource, entityDescriptor );
}