java.lang.Object
ch.tocco.nice2.persist.core.impl.hibernate.query.selection.CustomSelection

public class CustomSelection extends Object
Class to be used to specify a custom selection for a CriteriaQueryBuilder.
  • Constructor Details

  • Method Details

    • addPath

      public CustomSelection addPath(String... values)
      Add a path that should be selected from the query. The path can be nested or point to a to-many field. For example: - 'firstname' - 'relAddress.street' - 'relAddress.relType.unique_id' - 'relUser'
    • toJpaSelection

      public javax.persistence.criteria.Selection<?> toJpaSelection()
      Combine all selected paths into a JPA Selection instance.
    • numberOfSelectedPaths

      public int numberOfSelectedPaths()
    • mapResults

      public <RT> void mapResults(List<RT> target, List<Object[]> queryResult, ResultRowMapper<RT> mapper)
    • setToManyPathResultLimit

      public void setToManyPathResultLimit(int limit)