Examples of JuEmUtil


Examples of ch.inftec.ju.db.JuEmUtil

   * Create a new DbDataUtil that will use the specified EntityManager to get
   * a raw connection to the DB and execute SQL queries.
   * @param em EntityManager instance to execute SQL in a JDBC connection
   */
  public DbDataUtil(EntityManager em) {
    this(new JuEmUtil(em));
  }
View Full Code Here

Examples of ch.inftec.ju.db.JuEmUtil

   * @param doc XML Document of an (optional) data export. If no data was exported, the
   * document will be null
   */
  public final void init(EntityManager em, Document doc) {
    this.em = em;
    this.emUtil = new JuEmUtil(em);
   
    if (doc != null) this.xg = new XPathGetter(doc);
  }
View Full Code Here

Examples of ch.inftec.ju.db.JuEmUtil

          }
         
          // Initialize protected fields of test class
          dbTest.emfWork = dbTest.emfUtil.startWork();
          dbTest.em = dbTest.emfWork.getEm();
          dbTest.emUtil = new JuEmUtil(dbTest.em);
         
          // Run test method
          base.evaluate();
         
          // Run post server code in own transaction
View Full Code Here

Examples of ch.inftec.ju.db.JuEmUtil

    this.emUtil = emUtil;
    this.tx = tx != null ? new TxHandler(tx) : new TxHandler(this.emUtil.getEm());
  }
 
  public DbSchemaUtil(EntityManager em) {
    this(new JuEmUtil(em));
  }
View Full Code Here

Examples of ch.inftec.ju.db.JuEmUtil

   * EntityManager that require a transaction to be active.
   * @param em EntityManager provided by the container
   * @param tx UserTransaction instance of a bean managed transaction context
   */
  public DbSchemaUtil(EntityManager em, UserTransaction tx) {
    this(new JuEmUtil(em), tx);
  }
View Full Code Here

Examples of ch.inftec.ju.db.JuEmUtil

   * Create a new DbDataUtil that will use the specified EntityManager to get
   * a raw connection to the DB and execute SQL queries.
   * @param em EntityManager instance to execute SQL in a JDBC connection
   */
  public DbDataUtil(EntityManager em) {
    this(new JuEmUtil(em));
  }
View Full Code Here

Examples of ch.inftec.ju.db.JuEmUtil

          }
         
          // Initialize protected fields of test class
          dbTest.emfWork = dbTest.emfUtil.startWork();
          dbTest.em = dbTest.emfWork.getEm();
          dbTest.emUtil = new JuEmUtil(dbTest.em);

          // Run test method
          base.evaluate();
         
          // Run post server code in own transaction
View Full Code Here

Examples of ch.inftec.ju.db.JuEmUtil

//  public DbSchemaUtil(JuEmUtil emUtil, JuConnUtil2 connUtil) {
//    this(emUtil, TxHandler.getDummyHandler(), connUtil);
//  }
// 
  public DbSchemaUtil(EntityManager em) {
    this(new JuEmUtil(em));
  }
View Full Code Here

Examples of ch.inftec.ju.db.JuEmUtil

   * @param em EntityManager provided by the container
   * @param tx UserTransaction instance of a bean managed transaction context
   */
  @Deprecated
  public DbSchemaUtil(EntityManager em, UserTransaction tx) {
    this(new JuEmUtil(em));
  }
View Full Code Here

Examples of ch.inftec.ju.db.JuEmUtil

  public SystemPropertyTempSetter runPreTestActionsInEjbContext(TestRunnerAnnotationHandler handler) throws Exception {
    SystemPropertyTempSetter tempSetter = handler.initContainerTestEnv();
   
    try (TxHandler txHandler = new TxHandler(this.tx, true)) {
      // Execute post test annotations (dataset exporting, data verifying)
      handler.executePreTestAnnotations(new JuEmUtil(this.em));
      txHandler.commit(); // Commit after data verifying / exporting
    } catch (Exception ex) {
      // Reset properties in case of an exception
      tempSetter.close();
      throw ex;
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.