@Test public void test() { List<Long> expectedResults = new ArrayList<Long>(Arrays.asList(uid1, uid2, uid3, uid4)); List<Long> results = sut.execute(themeId); assertEquals(expectedResults.size(), results.size()); assertTrue(results.containsAll(expectedResults)); }
@SuppressWarnings("unchecked") @Override public List<Long> execute(final Long inRequest) { return getEntityManager().createQuery("SELECT p.id FROM Person p WHERE p.theme.id = :id ").setParameter("id", inRequest).getResultList(); }
GetPeopleIdsUsingThemeByThemeId extends BaseArgDomainMapper<Long, List<Long>> { @SuppressWarnings("unchecked") @Override public List<Long> execute(final Long inRequest) { return getEntityManager().createQuery("SELECT p.id FROM Person p WHERE p.theme.id = :id ").setParameter("id", inRequest).getResultList(); } }
GetPeopleIdsUsingThemeByThemeId extends BaseArgDomainMapper<Long, List<Long>> { @SuppressWarnings("unchecked") @Override public List<Long> execute(final Long inRequest) { return getEntityManager().createQuery("SELECT p.id FROM Person p WHERE p.theme.id = :id ").setParameter("id", inRequest).getResultList(); }  }
GetPeopleIdsUsingThemeByThemeId extends BaseArgDomainMapper<Long, List<Long>> { @SuppressWarnings("unchecked") @Override public List<Long> execute(final Long inRequest) { return getEntityManager().createQuery("SELECT p.id FROM Person p WHERE p.theme.id = :id ").setParameter("id", inRequest).getResultList(); }  @SuppressWarnings("unchecked") @Override List<Long> execute(final Long inRequest); }
GetPeopleIdsUsingThemeByThemeId extends BaseArgDomainMapper<Long, List<Long>> { @SuppressWarnings("unchecked") @Override public List<Long> execute(final Long inRequest) { return getEntityManager().createQuery("SELECT p.id FROM Person p WHERE p.theme.id = :id ").setParameter("id", inRequest).getResultList(); }  @SuppressWarnings("unchecked") @Override List<Long> execute(final Long inRequest);  }