@RequiresSession
  public List<WidgetLayoutEntity> findByName(Long clusterId, String layoutName, String userName) {
    TypedQuery<WidgetLayoutEntity> query = entityManagerProvider.get()
      .createNamedQuery("WidgetLayoutEntity.findByName", WidgetLayoutEntity.class);
    query.setParameter("clusterId", clusterId);
    query.setParameter("layoutName", layoutName);
    query.setParameter("userName", userName);

    return daoUtils.selectList(query);
  }
DAO utilities for dealing mostly with {@link TypedQuery} results.
ambari-server/src/main/java/org/apache/ambari/server/orm/dao/WidgetLayoutDAO.java