Examples of create()


Examples of org.jboss.test.jca.interfaces.PreparedStatementHome.create()

   public void testPreparedStatementCache() throws Exception
   {
      log.info("+++ testPreparedStatementCache");
      InitialContext ctx = new InitialContext();
      PreparedStatementHome home = (PreparedStatementHome) ctx.lookup("PreparedStatementBean");
      PreparedStatementRemote bean = home.create("key1", "name1");
      bean.testPreparedStatementCache();
      bean.remove();
   }

   public void testPreparedStatementCacheDoubleClose() throws Exception

Examples of org.jboss.test.jca.interfaces.ReentrantHome.create()

   }

   public void testReentrantConnectionCaching() throws Exception
   {
      ReentrantHome rh = (ReentrantHome)new InitialContext().lookup("/ejb/jca/Reentrant");
      Reentrant r1 = rh.create(new Integer(0), null);
      rh.create(new Integer(1), r1);
   }

}// ReentrantUnitTestCase

Examples of org.jboss.test.jca.interfaces.TransactionActiveHome.create()

   }

   public void testJDBCTransactionActive() throws Exception
   {
      TransactionActiveHome home = (TransactionActiveHome) getInitialContext().lookup("test/ejbs/TxActiveBean");
      TransactionActiveRemote remote = home.create();
      remote.setupDatabase();
      remote.changeDatabase();
      remote.checkDatabase();
   }

Examples of org.jboss.test.jca.interfaces.UnshareableConnectionStatefulLocalHome.create()

      try
      {
         InitialContext ctx = new InitialContext();
         Context enc = (Context) ctx.lookup("java:comp/env");
         UnshareableConnectionStatefulLocalHome home = (UnshareableConnectionStatefulLocalHome) enc.lookup("local/UnshareableStateful");
         UnshareableConnectionStatefulLocal stateful = home.create();
         stateful.runTestPart1();
         stateful.runTestPart2();
         stateful.remove();
      }
      catch (Exception e)

Examples of org.jboss.test.jca.interfaces.UserTxSessionHome.create()

   }

   public void testCachedConnectionError() throws Exception
   {
      UserTxSessionHome sh = (UserTxSessionHome) getInitialContext().lookup("UserTxSession");
      UserTxSession s = sh.create();
      try
      {
         s.testUnclosedError();
         fail("Should not be here");
      }

Examples of org.jboss.test.jca.interfaces.XAExceptionSessionHome.create()

   }

   public void testXAExceptionToTransactionRolledbackException() throws Exception
   {
      XAExceptionSessionHome xh = (XAExceptionSessionHome)getInitialContext().lookup("test/XAExceptionSessionHome");
      XAExceptionSession x = xh.create();
      try
      {
         x.testXAExceptionToTransactionRolledbackException();
      }
      catch (TransactionRolledbackException tre)

Examples of org.jboss.test.jca.interfaces.XAExceptionSessionLocalHome.create()

   {
      try
      {
         XAExceptionSessionLocalHome xh = (XAExceptionSessionLocalHome) new InitialContext()
               .lookup("test/XAExceptionSessionLocalHome");
         XAExceptionSessionLocal x = xh.create();
         try
         {
            x.testXAExceptionToTransactionRolledbackException();
         }
         catch (TransactionRolledbackLocalException tre)

Examples of org.jboss.test.jca.interfaces.XAExceptionTestSessionHome.create()

   }

   public void testXAExceptionToTransactionRolledbackExceptionOnServer() throws Exception
   {
      XAExceptionTestSessionHome xth = (XAExceptionTestSessionHome)getInitialContext().lookup("test/XAExceptionTestSessionHome");
      XAExceptionTestSession xt = xth.create();
      xt.testXAExceptionToTransactionRolledbackException();
   }

   public void testXAExceptionToTransactionRolledbackLocalExceptionOnServer() throws Exception
   {

Examples of org.jboss.test.jca.securedejb.CallerIdentityHome.create()

         log.debug("ejbcaller user setup failed", ignore);
      }

      LoginContext lc = login("ejbcaller", "ejbcallerpw".toCharArray());
      CallerIdentityHome home = (CallerIdentityHome) ctx.lookup("jca-test/CallerIdentity");
      CallerIdentity bean = home.create();
      bean.useCallerForAuth();
      lc.logout();
   }

   public void testConfiguredIdentityPropagation() throws Throwable

Examples of org.jboss.test.jmsra.bean.JMSSessionHome.create()

   public void testSendToQueueAndTopic()
      throws Exception
   {
      JMSSessionHome home = (JMSSessionHome) getInitialContext().lookup("JMSSession");
      JMSSession session = home.create();
      session.sendToQueueAndTopic();
   }

   public static Test suite() throws Exception
   {
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.