/*
 * 
 * 
 */

package sample.ejbs;

import java.util.List;
import javax.ejb.Stateless;
import javax.persistence.EntityManager;
import javax.persistence.PersistenceContext;
import sample.ejb.entity.Customer;

/**
 *
 * @author Pablito
 */
@Stateless
public class OtherSessionBean implements OtherSessionBeanLocal {

    @PersistenceContext
    EntityManager em;

    @Override
    public List<Customer> getAllCustomers() {
        return em.createQuery("Select c From Customer c").getResultList();
    }
 
}
