All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.github.alittlehuang.data.query.specification.CriteriaBuilder Maven / Gradle / Ivy

The newest version!
package com.github.alittlehuang.data.query.specification;

import javax.persistence.LockModeType;
import javax.persistence.criteria.JoinType;

/**
 * @author ALittleHuang
 */
public interface CriteriaBuilder> extends WhereClauseBuilder {

    THIS addSelect(String... paths);

    THIS addSelect(Expressions expression);

    THIS addSelect(Expressions expression, AggregateFunctions aggregate);

    THIS addGroupings(String... paths);

    THIS addGroupings(Expressions expression);

    THIS addOrdersAsc(String... paths);

    THIS addOrdersAsc(Expressions expression);

    THIS addOrdersDesc(String... paths);

    THIS addOrdersDesc(Expressions expression);

    THIS fetch(String... paths);

    THIS fetch(String paths, JoinType joinType);

    THIS fetch(Expressions expression);

    THIS fetch(Expressions expression, JoinType joinType);

    THIS setOffset(long offset);

    THIS setMaxResult(long maxResult);

    /**
     * set pageable, it will call
     * {@link CriteriaBuilder#setOffset(long)} and
     * {@link CriteriaBuilder#setMaxResult(long)}
     *
     * @param page Starting from zero
     * @param size max size per page
     * @return self
     */
    THIS setPageable(long page, long size);

    THIS setLockModeType(LockModeType lockModeType);

    Criteria getCriteria();

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy