List of usage examples for javax.persistence.criteria Root get
<Y> Path<Y> get(SingularAttribute<? super X, Y> attribute);
From source file:th.co.geniustree.dental.spec.LotSpec.java
public static Specification<Lot> dateOutBetween(final Date keyword) { return new Specification<Lot>() { @Override//from w w w .j a va 2s .c o m public Predicate toPredicate(Root<Lot> root, CriteriaQuery<?> cq, CriteriaBuilder cb) { return cb.between(root.get(Lot_.dateOut), keyword, keyword); } }; }
From source file:th.co.geniustree.intenship.advisor.spec.InformationSpec.java
public static Specification<Information> startTimeLike(final Date start, final Date end) { String startTime = Information_.startTime + ""; return new Specification<Information>() { @Override/*from w w w . j a v a 2s . com*/ public Predicate toPredicate(Root<Information> root, CriteriaQuery<?> cq, CriteriaBuilder cb) { return cb.between(root.get(Information_.startTime), start, end); } }; }
From source file:th.co.geniustree.intenship.advisor.spec.ParentSpec.java
public static Specification<Parent> nameLike(final String keyword) { return new Specification<Parent>() { @Override// w w w.ja va 2 s. c om public Predicate toPredicate(Root<Parent> root, CriteriaQuery<?> cq, CriteriaBuilder cb) { return cb.like(cb.upper(root.get(Parent_.name)), keyword.toUpperCase()); } }; }
From source file:th.co.geniustree.dental.spec.DepartmentSpec.java
public static Specification<Department> namelike(final String keyword) { return new Specification<Department>() { @Override/*from ww w . j ava2s. co m*/ public Predicate toPredicate(Root<Department> root, CriteriaQuery<?> cq, CriteriaBuilder cb) { return cb.like(cb.upper(root.get(Department_.name)), keyword.toUpperCase()); } }; }
From source file:th.co.geniustree.intenship.advisor.spec.ParentSpec.java
public static Specification<Parent> emailLike(final String keyword) { return new Specification<Parent>() { @Override/*from ww w. j a v a2 s . c o m*/ public Predicate toPredicate(Root<Parent> root, CriteriaQuery<?> query, CriteriaBuilder cb) { return cb.like(cb.upper(root.get(Parent_.email)), keyword.toUpperCase()); } }; }
From source file:th.co.geniustree.intenship.advisor.spec.StudentSpec.java
public static Specification<Student> emailLike(final String keyword) { return new Specification<Student>() { @Override//from w ww . j a va2 s . c o m public Predicate toPredicate(Root<Student> root, CriteriaQuery<?> query, CriteriaBuilder cb) { return cb.like(cb.upper(root.get(Student_.email)), keyword.toUpperCase()); } }; }
From source file:th.co.geniustree.intenship.advisor.spec.AccountSpec.java
public static Specification<Account> nameLike(final String keyword) { return new Specification<Account>() { @Override/*w ww . j a v a 2s . c o m*/ public Predicate toPredicate(Root<Account> root, CriteriaQuery<?> cq, CriteriaBuilder cb) { return cb.like(cb.upper(root.get(Account_.name)), keyword.toUpperCase()); } }; }
From source file:th.co.geniustree.intenship.advisor.spec.StudentSpec.java
public static Specification<Student> nameLike(final String keyword) { return new Specification<Student>() { @Override/*from w w w .ja va 2 s . co m*/ public Predicate toPredicate(Root<Student> root, CriteriaQuery<?> query, CriteriaBuilder cb) { return cb.like(cb.upper(root.get(Student_.name)), keyword.toUpperCase()); } }; }
From source file:th.co.geniustree.intenship.advisor.spec.AccountSpec.java
public static Specification<Account> emailLike(final String keyword) { return new Specification<Account>() { @Override//from ww w . j a va 2 s .c om public Predicate toPredicate(Root<Account> root, CriteriaQuery<?> query, CriteriaBuilder cb) { return cb.like(cb.upper(root.get(Account_.email)), keyword.toUpperCase()); } }; }
From source file:th.co.geniustree.intenship.advisor.spec.InformationSpec.java
public static Specification<Information> titleLike(final String keyword) { return new Specification<Information>() { @Override/*from w w w. j av a 2 s . c om*/ public Predicate toPredicate(Root<Information> root, CriteriaQuery<?> cq, CriteriaBuilder cb) { return cb.like(cb.upper(root.get(Information_.title)), keyword.toUpperCase()); } }; }