How to retrieve mapping table name for an entity in JPA at runtime?
Is it possible to determine the native table name of an entity?
If a Table annotation is present it's easy:
entityClass.getAnnotation(Table.class).name()
But what about if no Table annotation is present?
Hibernate provides this information via the Configuration class:
configuration.getClassMapping(entityClass.getSimpleName()).getTable().getName()
Is there something similar in JPA?