ModeShape Distribution 3.0.0.Beta4

org.modeshape.jcr.query.lucene
Class LuceneQueryEngine.LuceneQueryProcessor

java.lang.Object
  extended by org.modeshape.jcr.query.process.QueryProcessor<LuceneProcessingContext>
      extended by org.modeshape.jcr.query.lucene.LuceneQueryEngine.LuceneQueryProcessor
All Implemented Interfaces:
Processor
Enclosing class:
LuceneQueryEngine

protected static class LuceneQueryEngine.LuceneQueryProcessor
extends QueryProcessor<LuceneProcessingContext>

The QueryProcessor implementation used by this LuceneQueryEngine. It varies from the abstract class only by creating a LuceneQueryEngine.LuceneAccessQuery for each access query, and which is resposible for submitting the access query to Lucene.


Constructor Summary
protected LuceneQueryEngine.LuceneQueryProcessor(String repositoryName, org.hibernate.search.SearchFactory searchFactory)
           
 
Method Summary
protected  void closeProcessingContext(LuceneProcessingContext processingContext)
          A method that can be overridden to close the supplied processing context.
protected  ProcessingComponent createAccessComponent(QueryCommand originalQuery, QueryContext context, PlanNode accessNode, QueryResults.Columns resultColumns, LuceneProcessingContext processingContext)
          Create the ProcessingComponent that processes a single PlanNode.Type.ACCESS branch of a query plan.
protected  LuceneProcessingContext createProcessingContext(QueryContext queryContext)
          A method that can be overridden by subclasses to create a single context object used for all the access queries for a single query.
protected  void initialize(LuceneSchema schema)
           
protected  boolean supportsPushDownExistConstraints()
           
 
Methods inherited from class org.modeshape.jcr.query.process.QueryProcessor
createColumnsFor, createComponent, execute
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LuceneQueryEngine.LuceneQueryProcessor

protected LuceneQueryEngine.LuceneQueryProcessor(String repositoryName,
                                                 org.hibernate.search.SearchFactory searchFactory)
Method Detail

initialize

protected void initialize(LuceneSchema schema)

supportsPushDownExistConstraints

protected boolean supportsPushDownExistConstraints()
Specified by:
supportsPushDownExistConstraints in class QueryProcessor<LuceneProcessingContext>

createProcessingContext

protected LuceneProcessingContext createProcessingContext(QueryContext queryContext)
Description copied from class: QueryProcessor
A method that can be overridden by subclasses to create a single context object used for all the access queries for a single query.

Overrides:
createProcessingContext in class QueryProcessor<LuceneProcessingContext>
Parameters:
queryContext - the context in which the query is being executed; never null
Returns:
the processing context object; may be null

closeProcessingContext

protected void closeProcessingContext(LuceneProcessingContext processingContext)
Description copied from class: QueryProcessor
A method that can be overridden to close the supplied processing context. This method will always be called after a call to QueryProcessor.createProcessingContext(QueryContext)

Overrides:
closeProcessingContext in class QueryProcessor<LuceneProcessingContext>
Parameters:
processingContext - the processing context in which the query is being executed; null if QueryProcessor.createProcessingContext(QueryContext) returned null

createAccessComponent

protected ProcessingComponent createAccessComponent(QueryCommand originalQuery,
                                                    QueryContext context,
                                                    PlanNode accessNode,
                                                    QueryResults.Columns resultColumns,
                                                    LuceneProcessingContext processingContext)
Description copied from class: QueryProcessor
Create the ProcessingComponent that processes a single PlanNode.Type.ACCESS branch of a query plan.

Specified by:
createAccessComponent in class QueryProcessor<LuceneProcessingContext>
Parameters:
originalQuery - the original query that is being executed; never null
context - the context in which query is being evaluated; never null
accessNode - the node in the query plan that represents the PlanNode.Type.ACCESS plan; never null
resultColumns - the columns that are to be returned; never null
processingContext - the processing context in which the query is being executed; null if QueryProcessor.createProcessingContext(QueryContext) returned null
Returns:
the processing component; may not be null

ModeShape Distribution 3.0.0.Beta4

Copyright © 2008-2012 JBoss, a division of Red Hat. All Rights Reserved.