Examples of IdColumnEntity


Examples of org.apache.cayenne.jpa.itest.ch9.entity.IdColumnEntity

    }

    public void testUserProvidedIdColumnAnnotation() throws Exception {
        getDbHelper().deleteAll("IdColumnEntity");

        IdColumnEntity o1 = new IdColumnEntity();
        o1.setIdValue(15);

        getEntityManager().persist(o1);
        getEntityManager().getTransaction().commit();

        assertEquals(15, getDbHelper().getInt("IdColumnEntity", "idcolumn"));
        assertEquals(15, o1.getIdValue());
    }
View Full Code Here

Examples of org.apache.cayenne.jpa.itest.ch9.entity.IdColumnEntity

    }

    public void testGeneratedIdColumnAnnotation() throws Exception {
        getDbHelper().deleteAll("IdColumnEntity");

        IdColumnEntity o1 = new IdColumnEntity();

        getEntityManager().persist(o1);
        getEntityManager().getTransaction().commit();

        assertTrue(getDbHelper().getInt("IdColumnEntity", "idcolumn") > 0);
        assertTrue(o1.getIdValue() > 0);
    }
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.