Examples of ListResponse


Examples of com.akdeniz.googleplaycrawler.GooglePlay.ListResponse

    Assert.assertFalse(browseResponse.getCategoryList().isEmpty());
  }

  @Test(dependsOnMethods = { "shouldLogin" })
  public void shouldList() throws Exception {
    ListResponse listResponse = service.list("GAME", null, null, null);
    Assert.assertFalse(listResponse.getDocList().isEmpty());
  }
View Full Code Here

Examples of com.akdeniz.googleplaycrawler.GooglePlay.ListResponse

    Assert.assertFalse(listResponse.getDocList().isEmpty());
  }

  @Test(dependsOnMethods = { "shouldLogin" })
  public void shouldListSubCategories() throws Exception {
    ListResponse listResponse = service.list("GAME", "apps_topselling_free", 6, 36);
    Assert.assertFalse(listResponse.getDocList().isEmpty());
  }
View Full Code Here

Examples of com.akdeniz.googleplaycrawler.GooglePlay.ListResponse

  String packageName = namespace.getString("package");
  RECOMMENDATION_TYPE type = (RECOMMENDATION_TYPE) namespace.get("type");
  Integer offset = namespace.getInt("offset");
  Integer number = namespace.getInt("number");

  ListResponse recommendations = service.recommendations(packageName, type, offset, number);
 
  if (recommendations.getDoc(0).getChildCount() == 0) {
      System.out.println("No recommendation found!");
  } else {
    for (DocV2 child : recommendations.getDoc(0).getChildList()) {
      System.out.println(child.getDetails().getAppDetails().getPackageName());
    }
  }
    }
View Full Code Here

Examples of com.akdeniz.googleplaycrawler.GooglePlay.ListResponse

  String category = namespace.getString("category");
  String subcategory = namespace.getString("subcategory");
  Integer offset = namespace.getInt("offset");
  Integer number = namespace.getInt("number");

  ListResponse listResponse = service.list(category, subcategory, offset, number);
  if (subcategory == null) {
      System.out.println(SUBCATEGORIES_HEADER);
      for (DocV2 child : listResponse.getDocList()) {
    String formatted = new StringJoiner(DELIMETER).add(child.getDocid()).add(child.getTitle()).toString();
    System.out.println(formatted);
      }
  } else {
      System.out.println(LIST_HEADER);
      for (DocV2 child : listResponse.getDoc(0).getChildList()) {
    AppDetails appDetails = child.getDetails().getAppDetails();
    String formatted = new StringJoiner(DELIMETER).add(child.getTitle()).add(appDetails.getPackageName())
      .add(child.getCreator()).add(child.getOffer(0).getFormattedAmount())
      .add(String.valueOf(appDetails.getInstallationSize())).add(appDetails.getNumDownloads())
      .toString();
View Full Code Here

Examples of net.noderunner.amazon.s3.ListResponse

    * returns null if the parent node is not found or if no children are found.
    */
   public Set<String> getChildrenNames(Fqn name) throws Exception
   {
      String children = children(name);
      ListResponse response = connection.list(getBucket(), children);
      if (trace)
      {
         log.trace("getChildrenNames " + name + " response=" + response);
      }
      if (response.isNotFound())
         return null;
      if (!response.isOk())
         throw new Exception("List failed " + response);

      Set<String> set = new HashSet<String>();
      for (Entry e : response.getEntries())
      {
         // TODO decode prefix
         set.add(e.getKey().substring(children.length() + 1));
      }

View Full Code Here

Examples of org.apache.cayenne.util.ListResponse

                        // cache for future use
                        cache.snapshots.put(oidQuery.getObjectId(), result.get(0));
                    }
                }
                else {
                    response = new ListResponse();
                }
            }
            else {
                response = new ListResponse(row);
            }

            return DONE;
        }
View Full Code Here

Examples of org.apache.cayenne.util.ListResponse

        if (cache) {
            List cachedRows = this.cache.getCachedSnapshots(cacheKey);

            if (cachedRows != null) {
                // decorate result immutable list to avoid messing up the cache
                this.response = new ListResponse(Collections.unmodifiableList(cachedRows));

                if (cachedRows instanceof ListWithPrefetches) {
                    this.prefetchResultsByPath = ((ListWithPrefetches) cachedRows)
                            .getPrefetchResultsByPath();
                }
View Full Code Here

Examples of org.apache.cayenne.util.ListResponse

                if (response instanceof GenericResponse) {
                    ((GenericResponse) response).replaceResult(mainRows, objects);
                }
                else if (response instanceof ListResponse) {
                    this.response = new ListResponse(objects);
                }
                else {
                    throw new IllegalStateException("Unknown response object: "
                            + this.response);
                }
View Full Code Here

Examples of org.apache.cayenne.util.ListResponse

                    // do not return hollow objects
                    else if (((Persistent) object).getPersistenceState() == PersistenceState.HOLLOW) {
                        return !DONE;
                    }

                    this.response = new ListResponse(object);
                    return DONE;
                }
            }
        }
View Full Code Here

Examples of org.apache.cayenne.util.ListResponse

                    ? new SimpleIdIncrementalFaultList<Object>(
                            (DataContext) actingContext,
                            query)
                    : new IncrementalFaultList<Object>((DataContext) actingContext, query);

            response = new ListResponse(paginatedList);
            return DONE;
        }

        return !DONE;
    }
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.