public final class JpaUtils extends Object
Modifier and Type | Field and Description |
---|---|
static String |
DELETE_ALL_QUERY_STRING |
Modifier and Type | Method and Description |
---|---|
static <T> javax.persistence.Query |
applyAndBind(String queryString,
Iterable<T> entities,
javax.persistence.EntityManager entityManager)
Creates a where-clause referencing the given entities and appends it to the given query string.
|
static String |
detectAlias(String query)
Resolves the alias for the entity to be retrieved from the given JPA query.
|
static String |
getEntityName(javax.persistence.EntityManager em,
Class<?> entityClass) |
static String |
getQueryString(String template,
String entityName)
Returns the query string for the given class name.
|
public static final String DELETE_ALL_QUERY_STRING
public static String detectAlias(String query)
public static <T> javax.persistence.Query applyAndBind(String queryString, Iterable<T> entities, javax.persistence.EntityManager entityManager)
public static String getQueryString(String template, String entityName)
Copyright © 2018. All rights reserved.