@Test public void testFindGalleryItemCategories() { List<GalleryItemCategory> gadgetCategories = jpaGalleryItemCategoryMapper.findGalleryItemCategories(GalleryItemType.GADGET); assertTrue("No GalleryItemCategories found", gadgetCategories.size() > 0); }
@SuppressWarnings("unchecked") public List<GalleryItemCategory> findGalleryItemCategories(final GalleryItemType inGalleryItemType) { Query q = getEntityManager().createQuery( "from GalleryItemCategory" + " where galleryItemType = :galleryItemType") .setParameter("galleryItemType", inGalleryItemType); return q.getResultList(); }
GalleryItemCategoryMapper extends DomainEntityMapper<GalleryItemCategory> { @SuppressWarnings("unchecked") public List<GalleryItemCategory> findGalleryItemCategories(final GalleryItemType inGalleryItemType) { Query q = getEntityManager().createQuery( "from GalleryItemCategory" + " where galleryItemType = :galleryItemType") .setParameter("galleryItemType", inGalleryItemType); return q.getResultList(); } }
GalleryItemCategoryMapper extends DomainEntityMapper<GalleryItemCategory> { @SuppressWarnings("unchecked") public List<GalleryItemCategory> findGalleryItemCategories(final GalleryItemType inGalleryItemType) { Query q = getEntityManager().createQuery( "from GalleryItemCategory" + " where galleryItemType = :galleryItemType") .setParameter("galleryItemType", inGalleryItemType); return q.getResultList(); } GalleryItemCategoryMapper(final QueryOptimizer inQueryOptimizer); }
GalleryItemCategoryMapper extends DomainEntityMapper<GalleryItemCategory> { @SuppressWarnings("unchecked") public List<GalleryItemCategory> findGalleryItemCategories(final GalleryItemType inGalleryItemType) { Query q = getEntityManager().createQuery( "from GalleryItemCategory" + " where galleryItemType = :galleryItemType") .setParameter("galleryItemType", inGalleryItemType); return q.getResultList(); } GalleryItemCategoryMapper(final QueryOptimizer inQueryOptimizer); @SuppressWarnings("unchecked") GalleryItemCategory findByName(final GalleryItemType inGalleryItemType, final String inName); @SuppressWarnings("unchecked") List<GalleryItemCategory> findGalleryItemCategories(final GalleryItemType inGalleryItemType); }
GalleryItemCategoryMapper extends DomainEntityMapper<GalleryItemCategory> { @SuppressWarnings("unchecked") public List<GalleryItemCategory> findGalleryItemCategories(final GalleryItemType inGalleryItemType) { Query q = getEntityManager().createQuery( "from GalleryItemCategory" + " where galleryItemType = :galleryItemType") .setParameter("galleryItemType", inGalleryItemType); return q.getResultList(); } GalleryItemCategoryMapper(final QueryOptimizer inQueryOptimizer); @SuppressWarnings("unchecked") GalleryItemCategory findByName(final GalleryItemType inGalleryItemType, final String inName); @SuppressWarnings("unchecked") List<GalleryItemCategory> findGalleryItemCategories(final GalleryItemType inGalleryItemType);  }