|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.glassfish.persistence.jpa.JPAJava2DBProcessor
public class JPAJava2DBProcessor
For each persistence unit descriptors that is defined for an application create the ddl scripts. Additionally if the user has requested the tables to be created or dropped from the database complete that action too. These are the principles and expectations of the implementation. We don't want TopLink code to execute the DDLs, it should only generate them. So, we always set the *generation-mode* to *script* in the PUInfo object before passing it to createContainerEMF(). As a result TopLink never creates the actual tables, nor does it drop them. The DDLs are executed by our code based on user preference which considers inputs from persistence.xml and CLI. We set the TopLink property to DROP_AND_CREATE in that map because we want it to always generate both create- and dropDDL.jdbc files.
| Constructor Summary | |
|---|---|
JPAJava2DBProcessor(Java2DBProcessorHelper helper)
Creates a new instance of JPAJava2DBProcessor using Java2DBProcessorHelper |
|
| Method Summary | |
|---|---|
void |
createTablesInDB()
This method is called after the jdbc files have been created. |
boolean |
isJava2DbPU(PersistenceUnitDescriptor bundle)
This method does parses all relevant info from the PU |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public JPAJava2DBProcessor(Java2DBProcessorHelper helper)
helper - the Java2DBProcessorHelper instance to be used
with this processor.| Method Detail |
|---|
public boolean isJava2DbPU(PersistenceUnitDescriptor bundle)
bundle - the persistence unit descriptor that is being worked on.
public void createTablesInDB()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||