Examples of buildQuery()


Examples of org.jibeframework.alfresco.util.SearchContext.buildQuery()

    sc.setLocation(getPathFromSpaceRef(folder.getNodeRef(), true));
    sc.setText(expr);
    sc.setMode(searchMode);
    SearchParameters sp = new SearchParameters();
    sp.setLanguage(SearchService.LANGUAGE_LUCENE);
    query = sc.buildQuery(3);
    sp.setQuery(query);
    sp.addStore(AlfrescoUtil.getInstance().getStoreRef());
    List<CMObject> model = new ArrayList<CMObject>();
    ResultSet rs = null;
    try {
View Full Code Here

Examples of org.openengsb.core.edb.jpa.internal.util.QueryRequestCriteriaBuilder.buildQuery()

    public List<JPAObject> query(QueryRequest request) throws EDBException {
        synchronized (entityManager) {
            LOGGER.debug("Perform query with the query object: {}", request);
            CriteriaBuilder criteriaBuilder = entityManager.getCriteriaBuilder();
            QueryRequestCriteriaBuilder builder = new QueryRequestCriteriaBuilder(request, criteriaBuilder);
            TypedQuery<JPAObject> typedQuery = entityManager.createQuery(builder.buildQuery());
            return typedQuery.getResultList();
        }
    }

    public void setEntityManager(EntityManager entityManager) {
View Full Code Here

Examples of org.sf.mustru.search.SearchQuestion.buildQuery()

   SearchQuestion qp = new SearchQuestion();
   String question = "What did Richard Feynman say upon hearing he would receive the Nobel Prize in Physics?";

  // String question = "what is the capital of california?";
   System.out.println("Question: " + question);
   try { System.out.println("Generated query: " + qp.buildQuery(question)); }
   catch (IOException ie) { System.out.println("IO Error: " + ie.getMessage()); }
 
   System.out.println("Ended testBuildQuery");
  }
 
View Full Code Here

Examples of org.sf.mustru.search.SearchQuestion.buildQuery()

     String text = Files.readFromFile(new File("/big/trec/data/trec4/part5/data/FT941-4782.txt"));
     text = StringTools.filterChars(text);
     SearchQuestion sq = new SearchQuestion();
     String question = " How much did Mercury spend on advertising in 1993?";
     sq.buildQuery(question);
     String bestPassage[] = SearchTools.bestPassages(text, sq.getNouns(), sq.getVerbs(), sq.getAdjectives(), sq.getBigrams(), sq.getEntities() );
     System.out.println("Best: " + bestPassage[0]);
     System.out.println("Second best: " + bestPassage[1]);
   }
   catch (IOException ie) { System.err.println("File Error: " + fileName + " " + ie.getMessage()); }
View Full Code Here

Examples of org.sonatype.nexus.component.services.internal.query.OrientQueryBuilder.buildQuery()

    return execute(new Function<ODatabaseDocumentTx, Long>()
    {
      @Override
      public Long apply(final ODatabaseDocumentTx db) {
        OrientQueryBuilder queryBuilder = orientQueryBuilder(db, entityClass, queryWith(restriction));
        String countQuery = queryBuilder.buildQuery(entityClass, true);
        return executeCount(db, countQuery, queryBuilder.getParameters());
      }
    });
  }
View Full Code Here

Examples of org.sonatype.nexus.component.services.internal.query.OrientQueryBuilder.buildQuery()

  protected <A extends Asset> List<A> findAssets(final ODatabaseDocumentTx db,
                                                 final Class<A> assetClass,
                                                 @Nullable final MetadataQuery metadataQuery) {
    checkAllNotNull(db, assetClass);
    OrientQueryBuilder queryBuilder = orientQueryBuilder(db, assetClass, metadataQuery);
    String query = queryBuilder.buildQuery(assetClass, false);
    return FluentIterable
        .from(executeQuery(db, query, queryBuilder.getParameters()))
        .transform(new Function<ODocument, A>()
        {
          @Override
View Full Code Here

Examples of org.sonatype.nexus.component.services.internal.query.OrientQueryBuilder.buildQuery()

  protected <C extends Component> List<C> findComponents(final ODatabaseDocumentTx db,
                                                         final Class<C> componentClass,
                                                         @Nullable final MetadataQuery metadataQuery) {
    checkAllNotNull(db, componentClass);
    OrientQueryBuilder queryBuilder = orientQueryBuilder(db, componentClass, metadataQuery);
    String query = queryBuilder.buildQuery(componentClass, false);
    return FluentIterable
        .from(executeQuery(db, query, queryBuilder.getParameters()))
        .transform(new Function<ODocument, C>()
        {
          @Override
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.