use of org.apache.deltaspike.data.impl.builder.part.QueryRoot in project deltaspike by apache.
the class MethodQueryBuilder method createJpaQuery.
private Query createJpaQuery(CdiQueryInvocationContext context) {
Parameters params = context.getParams();
QueryRoot root = context.getRepositoryMethodMetadata().getQueryRoot();
String jpqlQuery = context.applyQueryStringPostProcessors(root.getJpqlQuery());
context.setQueryString(jpqlQuery);
params.updateValues(root.getParameterUpdates());
Query result = params.applyTo(context.getEntityManager().createQuery(jpqlQuery));
return context.applyRestrictions(result);
}
Aggregations