Examples of findByPrimaryKey()


Examples of org.apache.tapestry.vlib.ejb.IPublisherHome.findByPrimaryKey()

        if (updated != null)
        {
            for (int i = 0; i < updated.length; i++)
            {
                IPublisher publisher = home.findByPrimaryKey(updated[i].getId());
                publisher.setName(updated[i].getName());
            }
        }

        if (deleted != null)
View Full Code Here

Examples of org.jboss.as.test.integration.ejb.entity.bmp.BMPLocalHome.findByPrimaryKey()

    @Test
    public void testFindByPrimaryKey() throws Exception {
        DataStore.DATA.clear();
        final BMPLocalHome home = getHome();
        DataStore.DATA.put(1099, "VALUE1099");
        BMPLocalInterface result = home.findByPrimaryKey(1099);
        Assert.assertEquals("VALUE1099", result.getMyField());
    }

    @Test
    public void testSingleResultFinderMethod() throws Exception {
View Full Code Here

Examples of org.jboss.test.bmp.interfaces.SimpleBMPHome.findByPrimaryKey()

            home.create (i + 3, ("Dummy "+i));

         try
         {
            getLog().debug ("trying to find Robert again");
            b1 = home.findByPrimaryKey (new Integer (2));
            getLog().debug ("getName (): "+b1.getName ());
         }
         catch (Exception _e)
         {
            getLog().debug (_e.toString ());
View Full Code Here

Examples of org.jboss.test.cluster.ejb2.basic.interfaces.EntityPKHome.findByPrimaryKey()

      try
      {
         InitialContext ctx = new InitialContext();
         Context enc = (Context) ctx.lookup("java:comp/env");
         home = (EntityPKHome) enc.lookup("ejb/EntityPKHome");
         EntityPK bean = home.findByPrimaryKey(theKey);
         msg = "Found EntityPK, bean="+bean;
         log.info(msg);
      }
      catch(FinderException e)
      {
View Full Code Here

Examples of org.jboss.test.cmp2.audit.interfaces.AuditHome.findByPrimaryKey()

      {
         LoginContext login = ApplicationCallbackHandler.login("audituser2", "user2");
         try
         {
            AuditHome home = getAuditEJB();
            Audit audit = home.findByPrimaryKey(id);
            audit.setStringValue(stringValue);
         }
         finally
         {
            if (login != null)
View Full Code Here

Examples of org.jboss.test.cmp2.audit.interfaces.AuditMappedHome.findByPrimaryKey()

      {
         LoginContext login = ApplicationCallbackHandler.login("audituser2", "user2");
         try
         {
            AuditMappedHome home = getAuditMappedEJB();
            AuditMapped audit = home.findByPrimaryKey(id);
            audit.setStringValue(stringValue);
         }
         finally
         {
            if (login != null)
View Full Code Here

Examples of org.jboss.test.cmp2.cmrtransaction.interfaces.TreeLocalHome.findByPrimaryKey()

        {
            TreeLocalHome tlh = getTreeLocalHome();
            TreeLocal tl = null;
            try
            {
                tl = tlh.findByPrimaryKey("Parent");
                tl.remove();
            }
            catch (ObjectNotFoundException f) {}
            try
            {
View Full Code Here

Examples of org.jboss.test.cmp2.ejbselect.ALocalHome.findByPrimaryKey()

         {
            e.printStackTrace();
         }

         beginTx();
         a = ah.findByPrimaryKey(id);
         a.setIntField(3);
         commitTx();

         sleepUntilEvicted();
         assertTrue(cacheListener.lastEvicted - lastEvicted >= maxAgeMs + 1000);
View Full Code Here

Examples of org.jboss.test.cmp2.keygen.ejb.IntegerPKLocalHome.findByPrimaryKey()

      UnknownPKLocal ejb1 = home.create("testHsqldbIntegerKeyGenerator");
      UnknownPKLocal ejb2 = home.create("testHsqldbIntegerKeyGenerator");
      try
      {
         Integer key = (Integer) ejb1.getPrimaryKey();
         UnknownPKLocal ejb1a = home.findByPrimaryKey(key);
         assertTrue(ejb1.isIdentical(ejb1a));
         assertTrue(ejb1.isIdentical(ejb2) == false);
         assertTrue(ejb1.getPrimaryKey().equals(ejb2.getPrimaryKey()) == false);
      }
      finally
View Full Code Here

Examples of org.jboss.test.cmp2.keygen.ejb.UnknownPKLocalHome.findByPrimaryKey()

      UnknownPKLocalHome home = getUnknownPKHome("local/TestHsqldbEJB");
      UnknownPKLocal ejb1 = home.create("testHsqldbKeyGenerator");
      UnknownPKLocal ejb2 = home.create("testHsqldbKeyGenerator");
      try
      {
         UnknownPKLocal ejb1a = home.findByPrimaryKey(ejb1.getPrimaryKey());
         assertTrue(ejb1.isIdentical(ejb1a));
         assertTrue(ejb1.isIdentical(ejb2) == false);
         assertTrue(ejb1.getPrimaryKey().equals(ejb2.getPrimaryKey()) == false);
      }
      finally
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.