Java Code Examples for javax.persistence.criteria.CriteriaBuilder.function()

The following are Jave code examples for showing how to use function() of the javax.persistence.criteria.CriteriaBuilder class. You can vote up the examples you like. Your votes will be used in our system to get more good examples.
Example 1
Project: esup-sgc   File: Card.java   Source Code and License Vote up 6 votes
private static Expression<Boolean> getFullTestSearchExpression(CriteriaBuilder cb, String searchString) {
    return cb.function("fts", Boolean.class, cb.literal(searchString));
}
 
Example 2
Project: esup-sgc   File: Card.java   Source Code and License Vote up 6 votes
private static Expression<Double> getFullTestSearchRanking(CriteriaBuilder cb, String searchString) {
    return cb.function("ts_rank", Double.class, cb.literal(searchString));
}