rendered paste body public boolean deleteBox(Long id){ Boxes box = new Boxes(); box = entityManager.find(Boxes.class, id); entityManager.remove(box); if(box==null){ return true; }else{ return false; } }public void remove(EntityId id) throws EntityNotFoundException, TransactionRequiredException { Entity entity = findbyId(id); try { entityManager.remove(entity); } catch(IllegalArgumentException e) { log.warn(e.getMessage()); throw new EntityNotFoundException(e); } catch(TransactionRequiredException e) { log.warn(e.getMessage()); throw e; }}