Package org.exist.indexing.lucene

Examples of org.exist.indexing.lucene.LuceneIndexWorker.queryField()


        DocumentSet docs = contextSequence.getDocumentSet();
        Item query = getKey(contextSequence, null);
        Properties options = parseOptions(contextSequence, null);
        try {
            if (Type.subTypeOf(query.getType(), Type.ELEMENT))
                preselectResult = index.queryField(context, getExpressionId(), docs, useContext ? contextSequence.toNodeSet() : null,
                    field, (Element) ((NodeValue)query).getNode(), NodeSet.DESCENDANT, options);
            else
                preselectResult = index.queryField(context, getExpressionId(), docs, useContext ? contextSequence.toNodeSet() : null,
                    field, query.getStringValue(), NodeSet.DESCENDANT, options);
        } catch (IOException | ParseException e) {
View Full Code Here


        try {
            if (Type.subTypeOf(query.getType(), Type.ELEMENT))
                preselectResult = index.queryField(context, getExpressionId(), docs, useContext ? contextSequence.toNodeSet() : null,
                    field, (Element) ((NodeValue)query).getNode(), NodeSet.DESCENDANT, options);
            else
                preselectResult = index.queryField(context, getExpressionId(), docs, useContext ? contextSequence.toNodeSet() : null,
                    field, query.getStringValue(), NodeSet.DESCENDANT, options);
        } catch (IOException | ParseException e) {
            throw new XPathException(this, "Error while querying full text index: " + e.getMessage(), e);
        }
        LOG.debug("Lucene query took " + (System.currentTimeMillis() - start));
View Full Code Here

          LuceneIndexWorker index = (LuceneIndexWorker)
            context.getBroker().getIndexController().getWorkerByIndexId(LuceneIndex.ID);
          Properties options = parseOptions(contextSequence, contextItem);
          try {
            if (Type.subTypeOf(query.getType(), Type.ELEMENT))
              result = index.queryField(context, getExpressionId(), docs, contextSet, field,
                  (Element)((NodeValue)query).getNode(), NodeSet.ANCESTOR, options);
            else
              result = index.queryField(context, getExpressionId(), docs, contextSet, field,
                  query.getStringValue(), NodeSet.ANCESTOR, options);
            } catch (IOException | ParseException e) {
View Full Code Here

          try {
            if (Type.subTypeOf(query.getType(), Type.ELEMENT))
              result = index.queryField(context, getExpressionId(), docs, contextSet, field,
                  (Element)((NodeValue)query).getNode(), NodeSet.ANCESTOR, options);
            else
              result = index.queryField(context, getExpressionId(), docs, contextSet, field,
                  query.getStringValue(), NodeSet.ANCESTOR, options);
            } catch (IOException | ParseException e) {
            throw new XPathException(this, e.getMessage());
          }
          if( context.getProfiler().traceFunctions() ) {
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.