com.devonfw.module.jpa.dataaccess.api.data.QueryDslSupport Maven / Gradle / Ivy
package com.devonfw.module.jpa.dataaccess.api.data;
import com.querydsl.core.types.EntityPath;
import com.querydsl.jpa.impl.JPADeleteClause;
import com.querydsl.jpa.impl.JPAQuery;
/**
* Interface for QueryDsl support. All (non-static) methods defined in this interface are considered as internal API of
* a {@link GenericRepository} in order to be used by Java8+ default-method implementations for simplicity. Never call
* such methods from outside the data-access layer.
*
* @param generic type of the entity to query.
*
* @since 3.0.0
*/
public interface QueryDslSupport {
/**
* Attention: Please read documentation of {@link QueryDslSupport} before usage.
*
* @return a new {@link JPAQuery}. In most cases you should prefer using {@link #newDslQuery(Object)} instead.
*/
JPAQuery newDslQuery();
/**
* Attention: Please read documentation of {@link QueryDslSupport} before usage.
*
* @param alias the {@link #newDslAlias() alias}.
* @return a new {@link JPAQuery} for the given {@link com.querydsl.core.alias.Alias}.
*/
JPAQuery newDslQuery(E alias);
/**
* Attention: Please read documentation of {@link QueryDslSupport} before usage.
*
* @param alias the {@link #newDslAlias() alias}.
* @return a new {@link JPADeleteClause} for the given {@link com.querydsl.core.alias.Alias}.
*/
JPADeleteClause newDslDeleteClause(E alias);
/**
* Attention: Please read documentation of {@link QueryDslSupport} before usage.
*
* @param entityPath the {@link EntityPath} to delete from.
* @return a new {@link JPADeleteClause} for the given {@link EntityPath}.
*/
JPADeleteClause newDslDeleteClause(EntityPath entityPath);
/**
* Attention: Please read documentation of {@link QueryDslSupport} before usage.
*
* @return a new QueryDSL {@link com.querydsl.core.alias.Alias} for the managed entity.
*/
E newDslAlias();
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy