Package org.springframework.data.domain

Examples of org.springframework.data.domain.Pageable


  public @ResponseBody
  Map<String, ? extends Object> list(@RequestParam int page,
      @RequestParam int start, @RequestParam int limit,
      @RequestParam(required = false) Object filter) throws Exception {
    try {
      Pageable pageable = new PageRequest(page - 1, limit);
      Page<UserUI> users = null;

      List<FilterRequest> filters = new ArrayList<FilterRequest>();
      filters.add(new FilterRequest("accountType", ACCOUNT_TYPE));
View Full Code Here


  public @ResponseBody
  Map<String, ? extends Object> list(@RequestParam int page,
      @RequestParam int start, @RequestParam int limit,
      @RequestParam(required = false) Object filter) throws Exception {
    try {
      Pageable pageable = new PageRequest(page - 1, limit);
      Page<UserUI> users = null;

      List<FilterRequest> filters = new ArrayList<FilterRequest>();
      filters.add(new FilterRequest("accountType", ACCOUNT_TYPE));
View Full Code Here

  public @ResponseBody
  Map<String, ? extends Object> list(@RequestParam int page,
      @RequestParam int start, @RequestParam int limit,
      @RequestParam(required = false) Object filter) throws Exception {
    try {
      Pageable pageable = new PageRequest(page - 1, limit);
      Page<ProductUI> products = null;

      List<FilterRequest> filters = new ArrayList<FilterRequest>();

      if (filter != null) {
View Full Code Here

  public @ResponseBody
  Map<String, ? extends Object> list(@RequestParam int page,
      @RequestParam int start, @RequestParam int limit,
      @RequestParam(required = false) Object filter) throws Exception {
    try {
      Pageable pageable = new PageRequest(page - 1, limit);
      Page<ProductGroupUI> groups = null;

      List<FilterRequest> filters = new ArrayList<FilterRequest>();

      if (filter != null) {
View Full Code Here

  public @ResponseBody
  Map<String, ? extends Object> list(@RequestParam int page,
      @RequestParam int start, @RequestParam int limit,
      @RequestParam(required = false) Object filter) throws Exception {
    try {
      Pageable pageable = new PageRequest(page - 1, limit);
      Page<PurchaseOrderUI> purchases = null;

      List<FilterRequest> filters = new ArrayList<FilterRequest>();

      if (filter != null) {
View Full Code Here

  Map<String, ? extends Object> list(@RequestParam int page,
      @RequestParam int start, @RequestParam int limit,
      @RequestParam(required = false) Object filter) throws Exception {
    try {
      // @ TODO Add filter logic
      Pageable pageable = new PageRequest(page - 1, limit);
      Page<UserPaymentUI> payments = null;

      List<FilterRequest> filters = new ArrayList<FilterRequest>();

      if (filter != null) {
View Full Code Here

  public @ResponseBody
  Map<String, ? extends Object> list(@RequestParam int page,
      @RequestParam int start, @RequestParam int limit,
      @RequestParam(required = false) Object filter) throws Exception {
    try {
      Pageable pageable = new PageRequest(page - 1, limit);
      Page<SalesOrderUI> saleOrders = null;

      List<FilterRequest> filters = new ArrayList<FilterRequest>();

      if (filter != null) {
View Full Code Here

      Distance maxDistance = accessor.getMaxDistance();
      if (maxDistance != null) {
        nearQuery.maxDistance(maxDistance).in(maxDistance.getMetric());
      }

      Pageable pageable = accessor.getPageable();
      if (pageable != null) {
        nearQuery.with(pageable);
      }

      MongoEntityMetadata<?> metadata = method.getEntityInformation();
View Full Code Here

   */
  @Test
  public void slicedExecutionShouldRetainNrOfElementsToSkip() {

    MongoQueryFake query = createQueryForMethod("findByLastname", String.class, Pageable.class);
    Pageable page1 = new PageRequest(0, 10);
    Pageable page2 = page1.next();

    query.execute(new Object[] { "fake", page1 });
    query.execute(new Object[] { "fake", page2 });

    ArgumentCaptor<Query> captor = ArgumentCaptor.forClass(Query.class);
View Full Code Here

   */
  @Test
  public void slicedExecutionShouldIncrementLimitByOne() {

    MongoQueryFake query = createQueryForMethod("findByLastname", String.class, Pageable.class);
    Pageable page1 = new PageRequest(0, 10);
    Pageable page2 = page1.next();

    query.execute(new Object[] { "fake", page1 });
    query.execute(new Object[] { "fake", page2 });

    ArgumentCaptor<Query> captor = ArgumentCaptor.forClass(Query.class);
View Full Code Here

TOP

Related Classes of org.springframework.data.domain.Pageable

Copyright © 2018 www.massapicom. 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.