return persons;
}
public List<Person> findWithinRectangle(double x1, double y1, double x2, double y2)
{
Envelope envelope = new Envelope(x1, x2, y1, y2);
Query q = em.createQuery("Select p from Person p where p.currentLocation IN :envelope");
q.setParameter("envelope", envelope);
List<Person> persons = q.getResultList();
return persons;
}