com.mkdoc.query
Interface QueryBuilder

All Known Implementing Classes:
AbstractQueryBuilder, ServletQueryBuilder

public interface QueryBuilder

A builder for query types.

Version:
0.4 2005-07-28
Author:
Philip Shaw

Field Summary
static java.lang.String APPEND_AND
          An AND keyword.
static java.lang.String APPEND_COMMA
          A comma separator.
static java.lang.String APPEND_OR
          An OR keyword.
static java.lang.String CONSTRUCT
          A CONSTRUCT query type.
static java.lang.String DELIMITERS
          Query delimiters.
static java.lang.String DISTINCT
          A DISTINCT keyword.
static java.lang.String FROM
          A FROM keyword.
static java.lang.String LIKE
          An SeRQL "LIKE" keyword.
static java.lang.String NOT_LIKE
          An SeRQL "NOT LIKE" keyword.
static java.lang.String QUOTE
          A double quote character separator.
static java.lang.String SELECT
          A SELECT query type.
static java.lang.String SPACE
          A single space character.
static java.lang.String USING
          A USING NAMESPACE declaration.
static java.lang.String WHERE
          A WHERE keyword.
 
Method Summary
 Query getQuery()
          Parse the query source and get a Query object.
 java.util.List getQueryTerms(java.lang.String query)
          Get query terms from a string input.
 void setApplicationProfile(ApplicationProfile profile)
          Set the application profile to use for interpreting queries.
 void setDistinct(boolean distinct)
          Specify whether to de-duplicate results.
 

Field Detail

SPACE

public static final java.lang.String SPACE
A single space character.

Since:
Version 0.2 2005-07-26
See Also:
Constant Field Values

APPEND_COMMA

public static final java.lang.String APPEND_COMMA
A comma separator.

Since:
Version 0.2 2005-07-26
See Also:
Constant Field Values

SELECT

public static final java.lang.String SELECT
A SELECT query type.

Since:
Version 0.2 2005-07-26
See Also:
Constant Field Values

CONSTRUCT

public static final java.lang.String CONSTRUCT
A CONSTRUCT query type.

Since:
Version 0.2 2005-07-26
See Also:
Constant Field Values

DISTINCT

public static final java.lang.String DISTINCT
A DISTINCT keyword.

Since:
Version 0.2 2005-07-26
See Also:
Constant Field Values

FROM

public static final java.lang.String FROM
A FROM keyword.

Since:
Version 0.2 2005-07-26
See Also:
Constant Field Values

APPEND_AND

public static final java.lang.String APPEND_AND
An AND keyword.

Since:
Version 0.2 2005-07-26
See Also:
Constant Field Values

APPEND_OR

public static final java.lang.String APPEND_OR
An OR keyword.

Since:
Version 0.2 2005-07-26
See Also:
Constant Field Values

WHERE

public static final java.lang.String WHERE
A WHERE keyword.

Since:
Version 0.2 2005-07-26
See Also:
Constant Field Values

USING

public static final java.lang.String USING
A USING NAMESPACE declaration.

Since:
Version 0.2 2005-07-26
See Also:
Constant Field Values

LIKE

public static final java.lang.String LIKE
An SeRQL "LIKE" keyword.

Since:
Version 0.2 2005-07-26
See Also:
Constant Field Values

NOT_LIKE

public static final java.lang.String NOT_LIKE
An SeRQL "NOT LIKE" keyword.

Since:
Version 0.2 2005-07-26
See Also:
Constant Field Values

QUOTE

public static final java.lang.String QUOTE
A double quote character separator.

Since:
Version 0.1 2005-07-05
See Also:
Constant Field Values

DELIMITERS

public static final java.lang.String DELIMITERS
Query delimiters.

Since:
Version 0.1 2005-07-05
See Also:
Constant Field Values
Method Detail

setApplicationProfile

public void setApplicationProfile(ApplicationProfile profile)
Set the application profile to use for interpreting queries.

Parameters:
profile - The application profile to use to prepare the query.
Since:
Version 0.1 2005-07-05

getQueryTerms

public java.util.List getQueryTerms(java.lang.String query)
Get query terms from a string input.

Parameters:
query - The contents of a single metadata query field, which may include multiple search terms separated by delimiters.
Returns:
A series of query terms extracted from the query field input.
Since:
Version 0.1 2005-07-05

setDistinct

public void setDistinct(boolean distinct)
Specify whether to de-duplicate results.

Parameters:
distinct - Whether to de-duplicate the results.
Since:
Version 0.1 2005-07-05

getQuery

public Query getQuery()
Parse the query source and get a Query object.

Returns:
A query based on the input source.
Since:
Version 0.1 2005-07-05