Nuxeo ECM Projects 5.4.3-SNAPSHOT

org.nuxeo.ecm.core.storage.sql.jdbc
Interface QueryMaker

All Known Implementing Classes:
CapturingQueryMaker, NXQLQueryMaker, TagQueryMaker

public interface QueryMaker

A Query Maker, that can transform a query string into a SQL statement.

Must have a zero-arg constructor.

Author:
Florent Guillaume

Nested Class Summary
static class QueryMaker.Query
          A SQL query that can be executed by the backend.
static class QueryMaker.QueryCannotMatchException
           
static class QueryMaker.QueryMakerException
           
 
Method Summary
 boolean accepts(String query)
          Checks if this query maker accepts a given query.
 QueryMaker.Query buildQuery(SQLInfo sqlInfo, Model model, Session.PathResolver pathResolver, String query, QueryFilter queryFilter, Object... params)
          Builds the query.
 String getName()
          Gets the name for this query maker.
 

Method Detail

getName

String getName()
Gets the name for this query maker.


accepts

boolean accepts(String query)
Checks if this query maker accepts a given query.

Called first.

Parameters:
query - the query
Returns:
true if the query is accepted

buildQuery

QueryMaker.Query buildQuery(SQLInfo sqlInfo,
                            Model model,
                            Session.PathResolver pathResolver,
                            String query,
                            QueryFilter queryFilter,
                            Object... params)
                            throws StorageException
Builds the query.

Parameters:
sqlInfo - the sql info
model - the model
pathResolver - the path resolver
query - the query
queryFilter - the query filter
params - additional parameters, maker-specific
Throws:
StorageException

Nuxeo ECM Projects 5.4.3-SNAPSHOT

Copyright © 2011 Nuxeo SAS. All Rights Reserved.