Examples of QueryResponse

Examples of com.antlersoft.ilanalyze.xmlintf.QueryResponse

          HandlerStack stack=new HandlerStack( parser.getXMLReader());
          QueryRequest request=new QueryRequest();
          DefaultHandler top=new QueryRequest.Element( request).readFromXML( stack);
          stack.pushHandlerStack( top);
          parser.parse( new InputSource( new StringReader( s)), top);
          QueryResponse response=bbq.getXMLIntf().PerformQuery(request);
          StringWriter out=new StringWriter();
          ElementTransformReader.writeElement( new QueryResponse.Element( response), out);
          String output=out.toString();
          messenger.writeString( output);
View Full Code Here

Examples of com.google.api.services.bigquery.model.QueryResponse

public void doGet(HttpServletRequest request, HttpServletResponse response) throws IOException {
  log.info("SERVLET doGet");

    // query = "select count(*) from [publicdata:samples.shakespeare]";
    QueryResponse qr = executeQuickQuery(jobs, projectid, query);
    String msg = qr.toPrettyString();
    log.info("Query: '" + query + "'\nResponse: " + msg);

    PrintWriter writer = response.getWriter();
View Full Code Here

Examples of com.rallydev.rest.response.QueryResponse

    public void shouldQueryOnePage() throws Exception {
        JsonObject response = buildQueryResponse(5);
        QueryRequest request = new QueryRequest("Defect");
        doReturn(new Gson().toJson(response)).when(api.client).doGet(request.toUrl());
        QueryResponse queryResponse = api.query(request);

        verify(api.client, times(1)).doGet(anyString());
        assertEquals(queryResponse.getTotalResultCount(), 5);
View Full Code Here

Examples of com.youtube.vitess.vtgate.QueryResponse

    Object session = null;
    if (reply.containsField("Session")) {
      session = reply.get("Session");
    return new QueryResponse(queryResult, session, error);
View Full Code Here

Examples of org.apache.cayenne.QueryResponse

            return null;

        // skip context cache lookup, go directly to its channel
        Query query = new ObjectIdQuery((ObjectId) nodeId);
        QueryResponse response = context.getChannel().onQuery(context, query);
        List objects = response.firstList();

        if (objects.size() == 0) {
            throw new CayenneRuntimeException("No object for ID exists: " + nodeId);
        else if (objects.size() > 1) {
View Full Code Here

Examples of org.apache.cayenne.QueryResponse

        // ensure that originating query is wrapped to include the right cache key....
        this.paginatedQuery = query;

        // select directly from the channel, bypassing the context. Otherwise our query
        // wrapper can be intercepted incorrectly
        QueryResponse response = context.getChannel().onQuery(context, query);

        List firstPage = response.firstList();

        // sanity check
        if (firstPage.size() > pageSize) {
            throw new IllegalArgumentException("Returned page size ("
                    + firstPage.size()
View Full Code Here

Examples of org.apache.cayenne.QueryResponse

        return eventManager;

    public QueryResponse onQuery(ObjectContext context, Query query) {

        QueryResponse response = (QueryResponse) send(
                new QueryMessage(query),

        // if needed, register objects in provided context, rewriting the response
        // (assuming all lists are mutable)

        if (context != null) {

            EntityResolver resolver = context.getEntityResolver();
            QueryMetadata info = query.getMetaData(resolver);

            if (!info.isFetchingDataRows()) {


                while (response.next()) {
                    if (response.isList()) {

                        List objects = response.currentList();

                        if (!objects.isEmpty()) {

                            DeepMergeOperation merger = new DeepMergeOperation(context);
View Full Code Here

Examples of org.apache.solr.client.solrj.response.QueryResponse

        //query.addSortField( "price", SolrQuery.ORDER.asc );

        // query the server
        //SearchResult result = new SearchResult(count);
        try {
            final QueryResponse rsp = this.server.query( query );
            final SolrDocumentList docs = rsp.getResults();
            return docs;
            // add the docs into the YaCy search result container
            for (SolrDocument doc: docs) {
View Full Code Here

Examples of org.apache.solr.client.solrj.response.QueryResponse

            QueryResponse response = server.query(params);*/
    logger.debug("Solr query terms: " + query);
      SolrQuery queryObj = new SolrQuery();
      QueryResponse response = null;
      try {
        response = server.query(queryObj);
      } catch (Exception e){
      List<SolrRecord> results = response.getBeans(SolrRecord.class);

    return results;
View Full Code Here

Examples of org.apache.solr.client.solrj.response.QueryResponse

  public void testAvroRoundTrip() throws Exception {
    String file = RESOURCES_DIR + "/test-documents" + "/sample-statuses-20120906-141433.avro";
    QueryResponse rsp = query("*:*");
    Iterator<SolrDocument> iter = rsp.getResults().iterator();
    ListMultimap<String, String> expectedFieldValues;
    expectedFieldValues = ImmutableListMultimap.of("id", "1234567890", "text", "sample tweet one", "user_screen_name", "fake_user1");
    assertEquals(expectedFieldValues, next(iter));
    expectedFieldValues = ImmutableListMultimap.of("id", "2345678901", "text", "sample tweet two", "user_screen_name", "fake_user2")
    assertEquals(expectedFieldValues, next(iter));
View Full Code Here
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.