Examples of QPerson


Examples of net.petrikainulainen.spring.datajpa.model.QPerson

* @author Petri Kainulainen
*/
public class PersonPredicates {

    public static Predicate lastNameIsLike(final String searchTerm) {
        QPerson person = QPerson.person;
        return person.lastName.startsWithIgnoreCase(searchTerm);
    }
View Full Code Here

Examples of org.springframework.data.mongodb.repository.QPerson

    operations.save(person);
  }

  @Test
  public void providesMongoQuery() {
    QPerson p = QPerson.person;
    QuerydslRepositorySupport support = new QuerydslRepositorySupport(operations) {};
    MongodbQuery<Person> query = support.from(p).where(p.lastname.eq("Matthews"));
    assertThat(query.uniqueResult(), is(person));
  }
View Full Code Here

Examples of org.springframework.data.mongodb.repository.QPerson

    person.setSkills(Arrays.asList("vocalist", "songwriter", "guitarist"));

    operations.save(person);

    QPerson p = QPerson.person;
    QuerydslRepositorySupport support = new QuerydslRepositorySupport(operations) {};

    MongodbQuery<Person> query = support.from(p).where(p.skills.any().in("guitarist"));

    assertThat(query.uniqueResult(), is(person));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.