/**
  * @param id
  * @return employee object
  */
 public Employee getEmployeeById(Long id) {
   return entityManager.findById(Employee.class, id);
 }
 /** @return a list of employees */
 public List<Employee> getAllEmployees() {
   EntityManager entityManager = new EntityManagerImpl();
   return entityManager.findAll(Employee.class);
 }
 /**
  * @param employee
  * @return employee object
  */
 public Employee updateEmployee(Employee employee) {
   return entityManager.update(employee);
 }
 /** @param employee */
 public void deleteEmployee(Employee employee) {
   entityManager.delete(employee);
 }
 /**
  * @param employee
  * @return employee object
  */
 public Employee insertEmployee(Employee employee) {
   return (Employee) entityManager.insert(employee);
 }