Added option to allow UserQuery tag to define a different default fieldName.

Standard use case for this is where users are presented with a GUI form with multiple input boxes, each targetting a different field and allowing "lucene syntax". The XML query template behind such a form would have a <UserQuery> tag for each form field, each defined with the appropriate choice of default field name.

Added Junit test for changing default field name, updated DTD for XML query syntax and regenerated HTML documentation.



git-svn-id: https://svn.apache.org/repos/asf/lucene/java/trunk@674975 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Mark Harwood 2008-07-08 21:50:06 +00:00
parent ddc7c290d0
commit 74c551fb88
8 changed files with 510 additions and 469 deletions

View File

@ -145,6 +145,8 @@ Passes content directly through to the standard LuceneQuery parser see "Lucene Q
<!ELEMENT UserQuery (#PCDATA)>
<!-- Optional boost for matches on this query. Values > 1 -->
<!ATTLIST UserQuery boost CDATA "1.0">
<!-- fieldName can optionally be defined here to change the default field used in the QueryParser -->
<!ATTLIST UserQuery fieldName CDATA #IMPLIED>
<!-- A query which is used to match all documents. This has a couple of uses:
<ol>

View File

@ -23,7 +23,7 @@ Influence score of a query's matches in a subtle way which can't be achieved usi
<a name='BooleanQuery'></a>
<br /><table class='elementTitle' summary="BooleanQuery"><tr><td class='leftElementTitle'>
&lt;BooleanQuery&gt;</td><td class='rightElementTitle'>
Child of <a href='#Clause'>Clause</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>
</td></tr></table>
<p>BooleanQuerys implement Boolean logic which controls how multiple Clauses should be interpreted.
Some clauses may represent optional Query criteria while others represent mandatory criteria.</p><p><span class='inTextTitle'>Example:</span> <em>Find articles about banks, preferably talking about mergers but nothing to do with "sumitomo"</em>
@ -128,7 +128,7 @@ Attribute of <a href='#Clause'>Clause</a>
<p>Controls if the clause is optional (should), mandatory (must) or unacceptable (mustNot)</p><p><span class='inTextTitle'>Possible values</span>: should, must, mustnot - <span class='inTextTitle'>Default value</span>: should</p><a name='CachedFilter'></a>
<br /><table class='elementTitle' summary="CachedFilter"><tr><td class='leftElementTitle'>
&lt;CachedFilter&gt;</td><td class='rightElementTitle'>
Child of <a href='#Filter'>Filter</a>, <a href='#ConstantScoreQuery'>ConstantScoreQuery</a>, <a href='#Clause'>Clause</a>
Child of <a href='#ConstantScoreQuery'>ConstantScoreQuery</a>, <a href='#Filter'>Filter</a>, <a href='#Clause'>Clause</a>
</td></tr></table>
<p>Caches any nested query or filter in an LRU (Least recently used) Cache. Cached queries, like filters, are turned into
Bitsets at a cost of 1 bit per document in the index. The memory cost of a cached query/filter is therefore numberOfDocsinIndex/8 bytes.
@ -179,7 +179,7 @@ RAM to eliminate the cost of building this filter from disk for every query</em>
<span class='inTextTitle'>Element's model:</span><p class='model'>(<a href='#BooleanQuery'>BooleanQuery</a> | <a href='#UserQuery'>UserQuery</a> | <a href='#FilteredQuery'>FilteredQuery</a> | <a href='#TermQuery'>TermQuery</a> | <a href='#TermsQuery'>TermsQuery</a> | <a href='#MatchAllDocsQuery'>MatchAllDocsQuery</a> | <a href='#ConstantScoreQuery'>ConstantScoreQuery</a> | <a href='#SpanOr'>SpanOr</a> | <a href='#SpanNear'>SpanNear</a> | <a href='#SpanOrTerms'>SpanOrTerms</a> | <a href='#SpanFirst'>SpanFirst</a> | <a href='#SpanNot'>SpanNot</a> | <a href='#SpanTerm'>SpanTerm</a> | <a href='#LikeThisQuery'>LikeThisQuery</a> | <a href='#BoostingQuery'>BoostingQuery</a> | <a href='#FuzzyLikeThisQuery'>FuzzyLikeThisQuery</a> | <a href='#RangeFilter'>RangeFilter</a> | <a href='#CachedFilter'>CachedFilter</a> | <a href='#TermsFilter'>TermsFilter</a> | <a href='#BooleanFilter'>BooleanFilter</a> | <a href='#DuplicateFilter'>DuplicateFilter</a>)</p><a name='UserQuery'></a>
<br /><table class='elementTitle' summary="UserQuery"><tr><td class='leftElementTitle'>
&lt;UserQuery&gt;</td><td class='rightElementTitle'>
Child of <a href='#Clause'>Clause</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>
</td></tr></table>
<p>Passes content directly through to the standard LuceneQuery parser see "Lucene Query Syntax"</p><p><span class='inTextTitle'>Example:</span> <em>Search for documents about John Smith or John Doe using standard LuceneQuerySyntax</em>
</p><pre>
@ -192,16 +192,21 @@ Child of <a href='#Clause'>Clause</a>, <a href='#BoostQuery'>BoostQuery</a>, <a
<tr>
<th class='subtitle'>Name</th><th class='subtitle'>Values</th><th class='subtitle'>Default</th></tr>
<tr><th colspan='3' height='1' class='ruler'></th></tr>
<tr><td><a href='#UserQuery_boost'>boost</a></td><td></td><td>1.0</td></tr></table></td></tr></table></blockquote>
<tr><td><a href='#UserQuery_boost'>boost</a></td><td></td><td>1.0</td></tr><tr><td><a href='#UserQuery_fieldName'>fieldName</a></td><td></td><td></td></tr></table></td></tr></table></blockquote>
<a name='UserQuery_boost'></a>
<br /><table class='attributeTitle' summary="boost"><tr><td class='leftAttributeTitle'>
@boost</td><td class='rightAttributeTitle'>
Attribute of <a href='#UserQuery'>UserQuery</a>
</td></tr></table>
<p>Optional boost for matches on this query. Values > 1</p><p><span class='inTextTitle'>Default value</span>: 1.0</p><a name='MatchAllDocsQuery'></a>
<p>Optional boost for matches on this query. Values > 1</p><p><span class='inTextTitle'>Default value</span>: 1.0</p><a name='UserQuery_fieldName'></a>
<br /><table class='attributeTitle' summary="fieldName"><tr><td class='leftAttributeTitle'>
@fieldName</td><td class='rightAttributeTitle'>
Attribute of <a href='#UserQuery'>UserQuery</a>
</td></tr></table>
<p>fieldName can optionally be defined here to change the default field used in the QueryParser</p><a name='MatchAllDocsQuery'></a>
<br /><table class='elementTitle' summary="MatchAllDocsQuery"><tr><td class='leftElementTitle'>
&lt;MatchAllDocsQuery/&gt;</td><td class='rightElementTitle'>
Child of <a href='#Clause'>Clause</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>
</td></tr></table>
<p>A query which is used to match all documents. This has a couple of uses:
<ol>
@ -222,7 +227,7 @@ used to select content rather than it's usual role of filtering the results of a
</pre><p></p><p class='emptyTagNote'>This element is always empty.</p><a name='TermQuery'></a>
<br /><table class='elementTitle' summary="TermQuery"><tr><td class='leftElementTitle'>
&lt;TermQuery&gt;</td><td class='rightElementTitle'>
Child of <a href='#Clause'>Clause</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>
</td></tr></table>
<p>a single term query - no analysis is done of the child text</p><p><span class='inTextTitle'>Example:</span> <em>Match on a primary key</em>
</p><pre>
@ -249,7 +254,7 @@ Attribute of <a href='#TermQuery'>TermQuery</a>
<p>fieldName must be defined here or is taken from the most immediate parent XML element that defines a "fieldName" attribute</p><a name='TermsQuery'></a>
<br /><table class='elementTitle' summary="TermsQuery"><tr><td class='leftElementTitle'>
&lt;TermsQuery&gt;</td><td class='rightElementTitle'>
Child of <a href='#Clause'>Clause</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>
</td></tr></table>
<p>The equivalent of a BooleanQuery with multiple optional TermQuery clauses.
Child text is analyzed using a field-specific choice of Analyzer to produce a set of terms that are ORed together in Boolean logic.
@ -290,7 +295,7 @@ Attribute of <a href='#TermsQuery'>TermsQuery</a>
<p>The minimum number of terms that should be present in any one document before it is considered to be a match.</p><p><span class='inTextTitle'>Default value</span>: 0</p><a name='FilteredQuery'></a>
<br /><table class='elementTitle' summary="FilteredQuery"><tr><td class='leftElementTitle'>
&lt;FilteredQuery&gt;</td><td class='rightElementTitle'>
Child of <a href='#Clause'>Clause</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>
</td></tr></table>
<p>Runs a Query and filters results to only those query matches that also match the Filter element.</p><p><span class='inTextTitle'>Example:</span> <em>Find all documents about Lucene that have a status of "published"</em>
</p><pre>
@ -328,7 +333,7 @@ Attribute of <a href='#FilteredQuery'>FilteredQuery</a>
<p>Optional boost for matches on this query. Values > 1</p><p><span class='inTextTitle'>Default value</span>: 1.0</p><a name='Query'></a>
<br /><table class='elementTitle' summary="Query"><tr><td class='leftElementTitle'>
&lt;Query&gt;</td><td class='rightElementTitle'>
Child of <a href='#FilteredQuery'>FilteredQuery</a>, <a href='#BoostingQuery'>BoostingQuery</a>
Child of <a href='#BoostingQuery'>BoostingQuery</a>, <a href='#FilteredQuery'>FilteredQuery</a>
</td></tr></table>
<p>Used to identify a nested Query element inside another container element. NOT a top-level query tag</p><blockquote><table summary='element info'><tr>
<td class='construct'><table summary="&lt;Query&gt;'s children">
@ -377,7 +382,7 @@ Child of <a href='#FilteredQuery'>FilteredQuery</a>
<span class='inTextTitle'>Element's model:</span><p class='model'>(<a href='#RangeFilter'>RangeFilter</a> | <a href='#CachedFilter'>CachedFilter</a> | <a href='#TermsFilter'>TermsFilter</a> | <a href='#BooleanFilter'>BooleanFilter</a> | <a href='#DuplicateFilter'>DuplicateFilter</a>)</p><a name='RangeFilter'></a>
<br /><table class='elementTitle' summary="RangeFilter"><tr><td class='leftElementTitle'>
&lt;RangeFilter/&gt;</td><td class='rightElementTitle'>
Child of <a href='#Filter'>Filter</a>, <a href='#ConstantScoreQuery'>ConstantScoreQuery</a>, <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#ConstantScoreQuery'>ConstantScoreQuery</a>, <a href='#Filter'>Filter</a>, <a href='#Clause'>Clause</a>
</td></tr></table>
<p>Filter used to limit query results to documents matching a range of field values</p><p><span class='inTextTitle'>Example:</span> <em>Search for documents about banks from the last 10 years</em>
</p><pre>
@ -426,7 +431,7 @@ Attribute of <a href='#RangeFilter'>RangeFilter</a>
<p>Controls if the upperTerm in the range is part of the allowed set of values</p><p><span class='inTextTitle'>Possible values</span>: true, false - <span class='inTextTitle'>Default value</span>: true</p><a name='SpanTerm'></a>
<br /><table class='elementTitle' summary="SpanTerm"><tr><td class='leftElementTitle'>
&lt;SpanTerm&gt;</td><td class='rightElementTitle'>
Child of <a href='#Include'>Include</a>, <a href='#Exclude'>Exclude</a>, <a href='#Clause'>Clause</a>, <a href='#SpanOr'>SpanOr</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Query'>Query</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#SpanNear'>SpanNear</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#SpanNear'>SpanNear</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#Include'>Include</a>, <a href='#SpanOr'>SpanOr</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Clause'>Clause</a>, <a href='#Exclude'>Exclude</a>
</td></tr></table>
<p>A single term used in a SpanQuery. These clauses are the building blocks for more complex "span" queries which test word proximity</p><p><span class='inTextTitle'>Example:</span> <em>Find documents using terms close to each other about mining and accidents</em>
</p><pre>
@ -459,7 +464,7 @@ Attribute of <a href='#SpanTerm'>SpanTerm</a>
<p>fieldName must be defined here or is taken from the most immediate parent XML element that defines a "fieldName" attribute</p><p><span class='inTextTitle'>Required</span></p><a name='SpanOrTerms'></a>
<br /><table class='elementTitle' summary="SpanOrTerms"><tr><td class='leftElementTitle'>
&lt;SpanOrTerms&gt;</td><td class='rightElementTitle'>
Child of <a href='#Include'>Include</a>, <a href='#Exclude'>Exclude</a>, <a href='#Clause'>Clause</a>, <a href='#SpanOr'>SpanOr</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Query'>Query</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#SpanNear'>SpanNear</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#SpanNear'>SpanNear</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#Include'>Include</a>, <a href='#SpanOr'>SpanOr</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Clause'>Clause</a>, <a href='#Exclude'>Exclude</a>
</td></tr></table>
<p>A field-specific analyzer is used here to parse the child text provided in this tag. The SpanTerms produced are ORed in terms of Boolean logic</p><p><span class='inTextTitle'>Example:</span> <em>Use SpanOrTerms as a more convenient/succinct way of expressing multiple choices of SpanTerms. This example looks for reports
using words describing a fatality near to references to miners</em>
@ -485,7 +490,7 @@ Attribute of <a href='#SpanOrTerms'>SpanOrTerms</a>
<p>fieldName must be defined here or is taken from the most immediate parent XML element that defines a "fieldName" attribute</p><p><span class='inTextTitle'>Required</span></p><a name='SpanOr'></a>
<br /><table class='elementTitle' summary="SpanOr"><tr><td class='leftElementTitle'>
&lt;SpanOr&gt;</td><td class='rightElementTitle'>
Child of <a href='#Include'>Include</a>, <a href='#Exclude'>Exclude</a>, <a href='#Clause'>Clause</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Query'>Query</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#SpanNear'>SpanNear</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#SpanNear'>SpanNear</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#Include'>Include</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Clause'>Clause</a>, <a href='#Exclude'>Exclude</a>
</td></tr></table>
<p>Takes any number of child queries from the Span family</p><p><span class='inTextTitle'>Example:</span> <em>Find documents using terms close to each other about mining and accidents</em>
</p><pre>
@ -519,7 +524,7 @@ Child of <a href='#Include'>Include</a>, <a href='#Exclude'>Exclude</a>, <a href
<span class='inTextTitle'>Element's model:</span><p class='model'>(<a href='#SpanOr'>SpanOr</a> | <a href='#SpanNear'>SpanNear</a> | <a href='#SpanOrTerms'>SpanOrTerms</a> | <a href='#SpanFirst'>SpanFirst</a> | <a href='#SpanNot'>SpanNot</a> | <a href='#SpanTerm'>SpanTerm</a>)*</p><a name='SpanNear'></a>
<br /><table class='elementTitle' summary="SpanNear"><tr><td class='leftElementTitle'>
&lt;SpanNear&gt;</td><td class='rightElementTitle'>
Child of <a href='#Include'>Include</a>, <a href='#Exclude'>Exclude</a>, <a href='#Clause'>Clause</a>, <a href='#SpanOr'>SpanOr</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Query'>Query</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#Include'>Include</a>, <a href='#SpanOr'>SpanOr</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Clause'>Clause</a>, <a href='#Exclude'>Exclude</a>
</td></tr></table>
<p>Takes any number of child queries from the Span family and tests for proximity</p><blockquote><table summary='element info'><tr>
<td class='construct'><table summary="&lt;SpanNear&gt;'s children">
@ -570,7 +575,7 @@ Attribute of <a href='#SpanNear'>SpanNear</a>
<p>Controls if matching terms have to appear in the order listed or can be reversed</p><p><span class='inTextTitle'>Possible values</span>: true, false - <span class='inTextTitle'>Default value</span>: true</p><a name='SpanFirst'></a>
<br /><table class='elementTitle' summary="SpanFirst"><tr><td class='leftElementTitle'>
&lt;SpanFirst&gt;</td><td class='rightElementTitle'>
Child of <a href='#Include'>Include</a>, <a href='#Exclude'>Exclude</a>, <a href='#Clause'>Clause</a>, <a href='#SpanOr'>SpanOr</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#SpanNear'>SpanNear</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#SpanNear'>SpanNear</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#Include'>Include</a>, <a href='#SpanOr'>SpanOr</a>, <a href='#Clause'>Clause</a>, <a href='#Exclude'>Exclude</a>
</td></tr></table>
<p>Looks for a SpanQuery match occuring near the beginning of a document</p><p><span class='inTextTitle'>Example:</span> <em>Find letters where the first 50 words talk about a resignation:</em>
</p><pre>
@ -612,7 +617,7 @@ Attribute of <a href='#SpanFirst'>SpanFirst</a>
<p>Optional boost for matches on this query. Values > 1</p><p><span class='inTextTitle'>Default value</span>: 1.0</p><a name='SpanNot'></a>
<br /><table class='elementTitle' summary="SpanNot"><tr><td class='leftElementTitle'>
&lt;SpanNot&gt;</td><td class='rightElementTitle'>
Child of <a href='#Include'>Include</a>, <a href='#Exclude'>Exclude</a>, <a href='#Clause'>Clause</a>, <a href='#SpanOr'>SpanOr</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Query'>Query</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#SpanNear'>SpanNear</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#SpanNear'>SpanNear</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#Include'>Include</a>, <a href='#SpanOr'>SpanOr</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Clause'>Clause</a>, <a href='#Exclude'>Exclude</a>
</td></tr></table>
<p>Finds documents matching a SpanQuery but not if matching another SpanQuery</p><p><span class='inTextTitle'>Example:</span> <em>Find documents talking about social services but not containing the word "public"</em>
</p><pre>
@ -681,7 +686,7 @@ Child of <a href='#SpanNot'>SpanNot</a>
<span class='inTextTitle'>Element's model:</span><p class='model'>(<a href='#SpanOr'>SpanOr</a> | <a href='#SpanNear'>SpanNear</a> | <a href='#SpanOrTerms'>SpanOrTerms</a> | <a href='#SpanFirst'>SpanFirst</a> | <a href='#SpanNot'>SpanNot</a> | <a href='#SpanTerm'>SpanTerm</a>)</p><a name='ConstantScoreQuery'></a>
<br /><table class='elementTitle' summary="ConstantScoreQuery"><tr><td class='leftElementTitle'>
&lt;ConstantScoreQuery&gt;</td><td class='rightElementTitle'>
Child of <a href='#Clause'>Clause</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>
</td></tr></table>
<p>a utility tag to wrap any filter as a query</p><p><span class='inTextTitle'>Example:</span> <em> Find all documents from the last 10 years </em>
</p><pre>
@ -717,7 +722,7 @@ Attribute of <a href='#ConstantScoreQuery'>ConstantScoreQuery</a>
<p>Optional boost for matches on this query. Values > 1</p><p><span class='inTextTitle'>Default value</span>: 1.0</p><a name='FuzzyLikeThisQuery'></a>
<br /><table class='elementTitle' summary="FuzzyLikeThisQuery"><tr><td class='leftElementTitle'>
&lt;FuzzyLikeThisQuery&gt;</td><td class='rightElementTitle'>
Child of <a href='#Clause'>Clause</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>
</td></tr></table>
<p>Performs fuzzy matching on "significant" terms in fields. Improves on "LikeThisQuery" by allowing for fuzzy variations of supplied fields.
Improves on FuzzyQuery by rewarding all fuzzy variants of a term with the same IDF rather than default fuzzy behaviour which ranks rarer
@ -798,7 +803,7 @@ Attribute of <a href='#Field'>Field</a>
<p>fieldName must be defined here or is taken from the most immediate parent XML element that defines a "fieldName" attribute</p><a name='LikeThisQuery'></a>
<br /><table class='elementTitle' summary="LikeThisQuery"><tr><td class='leftElementTitle'>
&lt;LikeThisQuery&gt;</td><td class='rightElementTitle'>
Child of <a href='#Clause'>Clause</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>
</td></tr></table>
<p>Cherry-picks "significant" terms from the example child text and queries using these words. By only using significant (read: rare) terms the
performance cost of the query is substantially reduced and large bodies of text can be used as example content.</p><p><span class='inTextTitle'>Example:</span> <em>Use a block of text as an example of the type of content to be found, ignoring the "Reuters" word which
@ -863,7 +868,7 @@ Attribute of <a href='#LikeThisQuery'>LikeThisQuery</a>
Values must be between 1 and 100</p><p><span class='inTextTitle'>Default value</span>: 30</p><a name='BoostingQuery'></a>
<br /><table class='elementTitle' summary="BoostingQuery"><tr><td class='leftElementTitle'>
&lt;BoostingQuery&gt;</td><td class='rightElementTitle'>
Child of <a href='#Clause'>Clause</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#BoostQuery'>BoostQuery</a>, <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>
</td></tr></table>
<p>Requires matches on the "Query" element and optionally boosts by any matches on the "BoostQuery".
Unlike a regular BooleanQuery the boost can be less than 1 to produce a subtractive rather than additive result
@ -953,7 +958,7 @@ Attribute of <a href='#BoostQuery'>BoostQuery</a>
effectively demotes results from Query that match this BoostQuery.</p><p><span class='inTextTitle'>Default value</span>: 1.0</p><a name='DuplicateFilter'></a>
<br /><table class='elementTitle' summary="DuplicateFilter"><tr><td class='leftElementTitle'>
&lt;DuplicateFilter/&gt;</td><td class='rightElementTitle'>
Child of <a href='#Filter'>Filter</a>, <a href='#ConstantScoreQuery'>ConstantScoreQuery</a>, <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#ConstantScoreQuery'>ConstantScoreQuery</a>, <a href='#Filter'>Filter</a>, <a href='#Clause'>Clause</a>
</td></tr></table>
<p>Removes duplicated documents from results where "duplicate" means documents share a value for a particular field such as a primary key</p><p><span class='inTextTitle'>Example:</span> <em>Find the latest version of each web page that mentions "Lucene"</em>
</p><pre>
@ -995,7 +1000,7 @@ assuming every document is a duplicate then finds the "master" documents to keep
unique and unmarks those documents that are a copy.</p><p><span class='inTextTitle'>Possible values</span>: full, fast - <span class='inTextTitle'>Default value</span>: full</p><a name='TermsFilter'></a>
<br /><table class='elementTitle' summary="TermsFilter"><tr><td class='leftElementTitle'>
&lt;TermsFilter&gt;</td><td class='rightElementTitle'>
Child of <a href='#Filter'>Filter</a>, <a href='#ConstantScoreQuery'>ConstantScoreQuery</a>, <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#ConstantScoreQuery'>ConstantScoreQuery</a>, <a href='#Filter'>Filter</a>, <a href='#Clause'>Clause</a>
</td></tr></table>
<p>Processes child text using a field-specific choice of Analyzer to produce a set of terms that are then used as a filter.</p><p><span class='inTextTitle'>Example:</span> <em>Find documents talking about Lucene written on a Monday or a Friday</em>
</p><pre>
@ -1024,7 +1029,7 @@ Attribute of <a href='#TermsFilter'>TermsFilter</a>
<p>fieldName must be defined here or is taken from the most immediate parent XML element that defines a "fieldName" attribute</p><a name='BooleanFilter'></a>
<br /><table class='elementTitle' summary="BooleanFilter"><tr><td class='leftElementTitle'>
&lt;BooleanFilter&gt;</td><td class='rightElementTitle'>
Child of <a href='#Filter'>Filter</a>, <a href='#ConstantScoreQuery'>ConstantScoreQuery</a>, <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#CachedFilter'>CachedFilter</a>, <a href='#ConstantScoreQuery'>ConstantScoreQuery</a>, <a href='#Filter'>Filter</a>, <a href='#Clause'>Clause</a>
</td></tr></table>
<p>A Filter equivalent to BooleanQuery that applies Boolean logic to Clauses containing Filters.
Unlike BooleanQuery a BooleanFilter can contain a single "mustNot" clause.</p><p><span class='inTextTitle'>Example:</span> <em>Find documents from the first quarter of this year or last year that are not in "draft" status</em>

View File

@ -41,7 +41,7 @@ positions in relation to each other and the documents containing them.</p><p>Cor
<a name='BooleanQuery'></a>
<br /><table class='elementTitle' summary="BooleanQuery"><tr><td class='leftElementTitle'>
&lt;BooleanQuery&gt;</td><td class='rightElementTitle'>
Child of <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#Query'>Query</a>
</td></tr></table>
<p>BooleanQuerys implement Boolean logic which controls how multiple Clauses should be interpreted.
Some clauses may represent optional Query criteria while others represent mandatory criteria.</p><p><span class='inTextTitle'>Example:</span> <em>Find articles about banks, preferably talking about mergers but nothing to do with "sumitomo"</em>
@ -185,7 +185,7 @@ RAM to eliminate the cost of building this filter from disk for every query</em>
<span class='inTextTitle'>Element's model:</span><p class='model'>(<a href='#BooleanQuery'>BooleanQuery</a> | <a href='#UserQuery'>UserQuery</a> | <a href='#FilteredQuery'>FilteredQuery</a> | <a href='#TermQuery'>TermQuery</a> | <a href='#TermsQuery'>TermsQuery</a> | <a href='#MatchAllDocsQuery'>MatchAllDocsQuery</a> | <a href='#ConstantScoreQuery'>ConstantScoreQuery</a> | <a href='#SpanOr'>SpanOr</a> | <a href='#SpanNear'>SpanNear</a> | <a href='#SpanOrTerms'>SpanOrTerms</a> | <a href='#SpanFirst'>SpanFirst</a> | <a href='#SpanNot'>SpanNot</a> | <a href='#SpanTerm'>SpanTerm</a> | <a href='#RangeFilter'>RangeFilter</a> | <a href='#CachedFilter'>CachedFilter</a>)</p><a name='UserQuery'></a>
<br /><table class='elementTitle' summary="UserQuery"><tr><td class='leftElementTitle'>
&lt;UserQuery&gt;</td><td class='rightElementTitle'>
Child of <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#Query'>Query</a>
</td></tr></table>
<p>Passes content directly through to the standard LuceneQuery parser see "Lucene Query Syntax"</p><p><span class='inTextTitle'>Example:</span> <em>Search for documents about John Smith or John Doe using standard LuceneQuerySyntax</em>
</p><pre>
@ -198,16 +198,21 @@ Child of <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>, <a href='#Cac
<tr>
<th class='subtitle'>Name</th><th class='subtitle'>Values</th><th class='subtitle'>Default</th></tr>
<tr><th colspan='3' height='1' class='ruler'></th></tr>
<tr><td><a href='#UserQuery_boost'>boost</a></td><td></td><td>1.0</td></tr></table></td></tr></table></blockquote>
<tr><td><a href='#UserQuery_boost'>boost</a></td><td></td><td>1.0</td></tr><tr><td><a href='#UserQuery_fieldName'>fieldName</a></td><td></td><td></td></tr></table></td></tr></table></blockquote>
<a name='UserQuery_boost'></a>
<br /><table class='attributeTitle' summary="boost"><tr><td class='leftAttributeTitle'>
@boost</td><td class='rightAttributeTitle'>
Attribute of <a href='#UserQuery'>UserQuery</a>
</td></tr></table>
<p>Optional boost for matches on this query. Values > 1</p><p><span class='inTextTitle'>Default value</span>: 1.0</p><a name='MatchAllDocsQuery'></a>
<p>Optional boost for matches on this query. Values > 1</p><p><span class='inTextTitle'>Default value</span>: 1.0</p><a name='UserQuery_fieldName'></a>
<br /><table class='attributeTitle' summary="fieldName"><tr><td class='leftAttributeTitle'>
@fieldName</td><td class='rightAttributeTitle'>
Attribute of <a href='#UserQuery'>UserQuery</a>
</td></tr></table>
<p>fieldName can optionally be defined here to change the default field used in the QueryParser</p><a name='MatchAllDocsQuery'></a>
<br /><table class='elementTitle' summary="MatchAllDocsQuery"><tr><td class='leftElementTitle'>
&lt;MatchAllDocsQuery/&gt;</td><td class='rightElementTitle'>
Child of <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#Query'>Query</a>
</td></tr></table>
<p>A query which is used to match all documents. This has a couple of uses:
<ol>
@ -228,7 +233,7 @@ used to select content rather than it's usual role of filtering the results of a
</pre><p></p><p class='emptyTagNote'>This element is always empty.</p><a name='TermQuery'></a>
<br /><table class='elementTitle' summary="TermQuery"><tr><td class='leftElementTitle'>
&lt;TermQuery&gt;</td><td class='rightElementTitle'>
Child of <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#Query'>Query</a>
</td></tr></table>
<p>a single term query - no analysis is done of the child text</p><p><span class='inTextTitle'>Example:</span> <em>Match on a primary key</em>
</p><pre>
@ -255,7 +260,7 @@ Attribute of <a href='#TermQuery'>TermQuery</a>
<p>fieldName must be defined here or is taken from the most immediate parent XML element that defines a "fieldName" attribute</p><a name='TermsQuery'></a>
<br /><table class='elementTitle' summary="TermsQuery"><tr><td class='leftElementTitle'>
&lt;TermsQuery&gt;</td><td class='rightElementTitle'>
Child of <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#Query'>Query</a>
</td></tr></table>
<p>The equivalent of a BooleanQuery with multiple optional TermQuery clauses.
Child text is analyzed using a field-specific choice of Analyzer to produce a set of terms that are ORed together in Boolean logic.
@ -296,7 +301,7 @@ Attribute of <a href='#TermsQuery'>TermsQuery</a>
<p>The minimum number of terms that should be present in any one document before it is considered to be a match.</p><p><span class='inTextTitle'>Default value</span>: 0</p><a name='FilteredQuery'></a>
<br /><table class='elementTitle' summary="FilteredQuery"><tr><td class='leftElementTitle'>
&lt;FilteredQuery&gt;</td><td class='rightElementTitle'>
Child of <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#Query'>Query</a>
</td></tr></table>
<p>Runs a Query and filters results to only those query matches that also match the Filter element.</p><p><span class='inTextTitle'>Example:</span> <em>Find all documents about Lucene that have a status of "published"</em>
</p><pre>
@ -426,7 +431,7 @@ Attribute of <a href='#RangeFilter'>RangeFilter</a>
<p>Controls if the upperTerm in the range is part of the allowed set of values</p><p><span class='inTextTitle'>Possible values</span>: true, false - <span class='inTextTitle'>Default value</span>: true</p><a name='SpanTerm'></a>
<br /><table class='elementTitle' summary="SpanTerm"><tr><td class='leftElementTitle'>
&lt;SpanTerm&gt;</td><td class='rightElementTitle'>
Child of <a href='#SpanNear'>SpanNear</a>, <a href='#Include'>Include</a>, <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>, <a href='#SpanOr'>SpanOr</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Exclude'>Exclude</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#SpanOr'>SpanOr</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Exclude'>Exclude</a>, <a href='#Clause'>Clause</a>, <a href='#Include'>Include</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#SpanNear'>SpanNear</a>, <a href='#Query'>Query</a>
</td></tr></table>
<p>A single term used in a SpanQuery. These clauses are the building blocks for more complex "span" queries which test word proximity</p><p><span class='inTextTitle'>Example:</span> <em>Find documents using terms close to each other about mining and accidents</em>
</p><pre>
@ -459,7 +464,7 @@ Attribute of <a href='#SpanTerm'>SpanTerm</a>
<p>fieldName must be defined here or is taken from the most immediate parent XML element that defines a "fieldName" attribute</p><p><span class='inTextTitle'>Required</span></p><a name='SpanOrTerms'></a>
<br /><table class='elementTitle' summary="SpanOrTerms"><tr><td class='leftElementTitle'>
&lt;SpanOrTerms&gt;</td><td class='rightElementTitle'>
Child of <a href='#SpanNear'>SpanNear</a>, <a href='#Include'>Include</a>, <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>, <a href='#SpanOr'>SpanOr</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Exclude'>Exclude</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#SpanOr'>SpanOr</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Exclude'>Exclude</a>, <a href='#Clause'>Clause</a>, <a href='#Include'>Include</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#SpanNear'>SpanNear</a>, <a href='#Query'>Query</a>
</td></tr></table>
<p>A field-specific analyzer is used here to parse the child text provided in this tag. The SpanTerms produced are ORed in terms of Boolean logic</p><p><span class='inTextTitle'>Example:</span> <em>Use SpanOrTerms as a more convenient/succinct way of expressing multiple choices of SpanTerms. This example looks for reports
using words describing a fatality near to references to miners</em>
@ -485,7 +490,7 @@ Attribute of <a href='#SpanOrTerms'>SpanOrTerms</a>
<p>fieldName must be defined here or is taken from the most immediate parent XML element that defines a "fieldName" attribute</p><p><span class='inTextTitle'>Required</span></p><a name='SpanOr'></a>
<br /><table class='elementTitle' summary="SpanOr"><tr><td class='leftElementTitle'>
&lt;SpanOr&gt;</td><td class='rightElementTitle'>
Child of <a href='#SpanNear'>SpanNear</a>, <a href='#Include'>Include</a>, <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Exclude'>Exclude</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#SpanFirst'>SpanFirst</a>, <a href='#Exclude'>Exclude</a>, <a href='#Clause'>Clause</a>, <a href='#Include'>Include</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#SpanNear'>SpanNear</a>, <a href='#Query'>Query</a>
</td></tr></table>
<p>Takes any number of child queries from the Span family</p><p><span class='inTextTitle'>Example:</span> <em>Find documents using terms close to each other about mining and accidents</em>
</p><pre>
@ -519,7 +524,7 @@ Child of <a href='#SpanNear'>SpanNear</a>, <a href='#Include'>Include</a>, <a hr
<span class='inTextTitle'>Element's model:</span><p class='model'>(<a href='#SpanOr'>SpanOr</a> | <a href='#SpanNear'>SpanNear</a> | <a href='#SpanOrTerms'>SpanOrTerms</a> | <a href='#SpanFirst'>SpanFirst</a> | <a href='#SpanNot'>SpanNot</a> | <a href='#SpanTerm'>SpanTerm</a>)*</p><a name='SpanNear'></a>
<br /><table class='elementTitle' summary="SpanNear"><tr><td class='leftElementTitle'>
&lt;SpanNear&gt;</td><td class='rightElementTitle'>
Child of <a href='#Include'>Include</a>, <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>, <a href='#SpanOr'>SpanOr</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Exclude'>Exclude</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#SpanOr'>SpanOr</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Exclude'>Exclude</a>, <a href='#Clause'>Clause</a>, <a href='#Include'>Include</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#Query'>Query</a>
</td></tr></table>
<p>Takes any number of child queries from the Span family and tests for proximity</p><blockquote><table summary='element info'><tr>
<td class='construct'><table summary="&lt;SpanNear&gt;'s children">
@ -570,7 +575,7 @@ Attribute of <a href='#SpanNear'>SpanNear</a>
<p>Controls if matching terms have to appear in the order listed or can be reversed</p><p><span class='inTextTitle'>Possible values</span>: true, false - <span class='inTextTitle'>Default value</span>: true</p><a name='SpanFirst'></a>
<br /><table class='elementTitle' summary="SpanFirst"><tr><td class='leftElementTitle'>
&lt;SpanFirst&gt;</td><td class='rightElementTitle'>
Child of <a href='#SpanNear'>SpanNear</a>, <a href='#Include'>Include</a>, <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>, <a href='#SpanOr'>SpanOr</a>, <a href='#Exclude'>Exclude</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#SpanOr'>SpanOr</a>, <a href='#Exclude'>Exclude</a>, <a href='#Clause'>Clause</a>, <a href='#Include'>Include</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#SpanNear'>SpanNear</a>, <a href='#Query'>Query</a>
</td></tr></table>
<p>Looks for a SpanQuery match occuring near the beginning of a document</p><p><span class='inTextTitle'>Example:</span> <em>Find letters where the first 50 words talk about a resignation:</em>
</p><pre>
@ -612,7 +617,7 @@ Attribute of <a href='#SpanFirst'>SpanFirst</a>
<p>Optional boost for matches on this query. Values > 1</p><p><span class='inTextTitle'>Default value</span>: 1.0</p><a name='SpanNot'></a>
<br /><table class='elementTitle' summary="SpanNot"><tr><td class='leftElementTitle'>
&lt;SpanNot&gt;</td><td class='rightElementTitle'>
Child of <a href='#SpanNear'>SpanNear</a>, <a href='#Include'>Include</a>, <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>, <a href='#SpanOr'>SpanOr</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Exclude'>Exclude</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#SpanOr'>SpanOr</a>, <a href='#SpanFirst'>SpanFirst</a>, <a href='#Exclude'>Exclude</a>, <a href='#Clause'>Clause</a>, <a href='#Include'>Include</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#SpanNear'>SpanNear</a>, <a href='#Query'>Query</a>
</td></tr></table>
<p>Finds documents matching a SpanQuery but not if matching another SpanQuery</p><p><span class='inTextTitle'>Example:</span> <em>Find documents talking about social services but not containing the word "public"</em>
</p><pre>
@ -681,7 +686,7 @@ Child of <a href='#SpanNot'>SpanNot</a>
<span class='inTextTitle'>Element's model:</span><p class='model'>(<a href='#SpanOr'>SpanOr</a> | <a href='#SpanNear'>SpanNear</a> | <a href='#SpanOrTerms'>SpanOrTerms</a> | <a href='#SpanFirst'>SpanFirst</a> | <a href='#SpanNot'>SpanNot</a> | <a href='#SpanTerm'>SpanTerm</a>)</p><a name='ConstantScoreQuery'></a>
<br /><table class='elementTitle' summary="ConstantScoreQuery"><tr><td class='leftElementTitle'>
&lt;ConstantScoreQuery&gt;</td><td class='rightElementTitle'>
Child of <a href='#Query'>Query</a>, <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>
Child of <a href='#Clause'>Clause</a>, <a href='#CachedFilter'>CachedFilter</a>, <a href='#Query'>Query</a>
</td></tr></table>
<p>a utility tag to wrap any filter as a query</p><p><span class='inTextTitle'>Example:</span> <em> Find all documents from the last 10 years </em>
</p><pre>

View File

@ -151,6 +151,8 @@
<span class="dtd_tag_symbols">&lt;!</span><span class="dtd_tag_name">ELEMENT</span><span class="dtd_plain"> </span><span class="dtd_attribute_name">UserQuery</span><span class="dtd_plain"> (</span><span class="dtd_keyword">#PCDATA</span><span class="dtd_plain">)</span><span class="dtd_tag_symbols">&gt;</span>
<span class="dtd_comment">&lt;!-- Optional boost for matches on this query. Values &gt; 1 --&gt;</span>
<span class="dtd_tag_symbols">&lt;!</span><span class="dtd_tag_name">ATTLIST</span><span class="dtd_plain"> </span><span class="dtd_attribute_name">UserQuery</span><span class="dtd_plain"> </span><span class="dtd_attribute_name">boost</span><span class="dtd_plain"> </span><span class="dtd_keyword">CDATA</span><span class="dtd_plain"> </span><span class="dtd_attribute_value">&quot;1.0&quot;</span><span class="dtd_tag_symbols">&gt;</span>
<span class="dtd_comment">&lt;!-- fieldName can optionally be defined here to change the default field used in the QueryParser --&gt;</span><span class="dtd_plain"> </span>
<span class="dtd_tag_symbols">&lt;!</span><span class="dtd_tag_name">ATTLIST</span><span class="dtd_plain"> </span><span class="dtd_attribute_name">UserQuery</span><span class="dtd_plain"> </span><span class="dtd_attribute_name">fieldName</span><span class="dtd_plain"> </span><span class="dtd_keyword">CDATA</span><span class="dtd_plain"> </span><span class="dtd_keyword">#IMPLIED</span><span class="dtd_tag_symbols">&gt;</span>
<span class="dtd_comment">&lt;!-- A query which is used to match all documents. This has a couple of uses: </span>
<span class="dtd_comment"> &lt;ol&gt;</span>

View File

@ -4,10 +4,10 @@
<link rel='StyleSheet' href='DTDDocStyle.css' type='text/css' media='screen' />
<link rel='StyleSheet' href='dtreeStyle.css' type='text/css' media='screen' />
<script type='text/javascript' src='cctree.js'></script>
<title>Lucene XML Query syntax, 09-Oct-2007</title>
<title>Lucene XML Query syntax, 08-Jul-2008</title>
</head><body>
<h1 class='TOCTitle'>Lucene XML Query syntax</h1>
<h2 class='TOCTitle'>09-Oct-2007</h2>
<h2 class='TOCTitle'>08-Jul-2008</h2>
<a href='elementsIndex.html' target='detail'>Elements' index</a><hr />
<div class='dtree'>
<script type='text/javascript'>
@ -41,467 +41,471 @@ eltTree.addNode('12','<b>UserQuery</b>','LuceneContribQuery.dtd.html#UserQuery',
eltTree.linkNodes('5','12')
eltTree.addNode('13','@boost','LuceneContribQuery.dtd.html#UserQuery_boost',false,false)
eltTree.linkNodes('12','13')
eltTree.addNode('14','<b>FilteredQuery</b>','LuceneContribQuery.dtd.html#FilteredQuery',false,false)
eltTree.linkNodes('5','14')
eltTree.addNode('15','@boost','LuceneContribQuery.dtd.html#FilteredQuery_boost',false,false)
eltTree.linkNodes('14','15')
eltTree.addNode('16','<b>Query</b>','LuceneContribQuery.dtd.html#Query',false,false)
eltTree.linkNodes('14','16')
eltTree.addNode('17','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('16','17')
eltTree.linkNodes('17','6','<b>BooleanQuery</b>')
eltTree.linkNodes('17','12','<b>UserQuery</b>')
eltTree.linkNodes('17','14','<b>FilteredQuery</b>')
eltTree.addNode('18','<b>TermQuery</b>','LuceneContribQuery.dtd.html#TermQuery',false,false)
eltTree.addNode('14','@fieldName','LuceneContribQuery.dtd.html#UserQuery_fieldName',false,false)
eltTree.linkNodes('12','14')
eltTree.addNode('15','<b>FilteredQuery</b>','LuceneContribQuery.dtd.html#FilteredQuery',false,false)
eltTree.linkNodes('5','15')
eltTree.addNode('16','@boost','LuceneContribQuery.dtd.html#FilteredQuery_boost',false,false)
eltTree.linkNodes('15','16')
eltTree.addNode('17','<b>Query</b>','LuceneContribQuery.dtd.html#Query',false,false)
eltTree.linkNodes('15','17')
eltTree.addNode('18','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('17','18')
eltTree.addNode('19','@boost','LuceneContribQuery.dtd.html#TermQuery_boost',false,false)
eltTree.linkNodes('18','6','<b>BooleanQuery</b>')
eltTree.linkNodes('18','12','<b>UserQuery</b>')
eltTree.linkNodes('18','15','<b>FilteredQuery</b>')
eltTree.addNode('19','<b>TermQuery</b>','LuceneContribQuery.dtd.html#TermQuery',false,false)
eltTree.linkNodes('18','19')
eltTree.addNode('20','@fieldName','LuceneContribQuery.dtd.html#TermQuery_fieldName',false,false)
eltTree.linkNodes('18','20')
eltTree.addNode('21','<b>TermsQuery</b>','LuceneContribQuery.dtd.html#TermsQuery',false,false)
eltTree.linkNodes('17','21')
eltTree.addNode('22','@boost','LuceneContribQuery.dtd.html#TermsQuery_boost',false,false)
eltTree.linkNodes('21','22')
eltTree.addNode('23','@disableCoord','LuceneContribQuery.dtd.html#TermsQuery_disableCoord',false,false)
eltTree.linkNodes('21','23')
eltTree.addNode('24','@fieldName','LuceneContribQuery.dtd.html#TermsQuery_fieldName',false,false)
eltTree.linkNodes('21','24')
eltTree.addNode('25','@minimumNumberShouldMatch','LuceneContribQuery.dtd.html#TermsQuery_minimumNumberShouldMatch',false,false)
eltTree.linkNodes('21','25')
eltTree.addNode('26','<b>&lt;MatchAllDocsQuery/&gt;</b>','LuceneContribQuery.dtd.html#MatchAllDocsQuery',false,false)
eltTree.linkNodes('17','26')
eltTree.addNode('27','<b>ConstantScoreQuery</b>','LuceneContribQuery.dtd.html#ConstantScoreQuery',false,false)
eltTree.linkNodes('17','27')
eltTree.addNode('28','@boost','LuceneContribQuery.dtd.html#ConstantScoreQuery_boost',false,false)
eltTree.linkNodes('27','28')
eltTree.addNode('29','<i>&lt;choice&gt;*</i>',null,true,false)
eltTree.linkNodes('27','29')
eltTree.addNode('30','<b>&lt;RangeFilter/&gt;</b>','LuceneContribQuery.dtd.html#RangeFilter',false,false)
eltTree.linkNodes('29','30')
eltTree.addNode('31','@fieldName','LuceneContribQuery.dtd.html#RangeFilter_fieldName',false,false)
eltTree.addNode('20','@boost','LuceneContribQuery.dtd.html#TermQuery_boost',false,false)
eltTree.linkNodes('19','20')
eltTree.addNode('21','@fieldName','LuceneContribQuery.dtd.html#TermQuery_fieldName',false,false)
eltTree.linkNodes('19','21')
eltTree.addNode('22','<b>TermsQuery</b>','LuceneContribQuery.dtd.html#TermsQuery',false,false)
eltTree.linkNodes('18','22')
eltTree.addNode('23','@boost','LuceneContribQuery.dtd.html#TermsQuery_boost',false,false)
eltTree.linkNodes('22','23')
eltTree.addNode('24','@disableCoord','LuceneContribQuery.dtd.html#TermsQuery_disableCoord',false,false)
eltTree.linkNodes('22','24')
eltTree.addNode('25','@fieldName','LuceneContribQuery.dtd.html#TermsQuery_fieldName',false,false)
eltTree.linkNodes('22','25')
eltTree.addNode('26','@minimumNumberShouldMatch','LuceneContribQuery.dtd.html#TermsQuery_minimumNumberShouldMatch',false,false)
eltTree.linkNodes('22','26')
eltTree.addNode('27','<b>&lt;MatchAllDocsQuery/&gt;</b>','LuceneContribQuery.dtd.html#MatchAllDocsQuery',false,false)
eltTree.linkNodes('18','27')
eltTree.addNode('28','<b>ConstantScoreQuery</b>','LuceneContribQuery.dtd.html#ConstantScoreQuery',false,false)
eltTree.linkNodes('18','28')
eltTree.addNode('29','@boost','LuceneContribQuery.dtd.html#ConstantScoreQuery_boost',false,false)
eltTree.linkNodes('28','29')
eltTree.addNode('30','<i>&lt;choice&gt;*</i>',null,true,false)
eltTree.linkNodes('28','30')
eltTree.addNode('31','<b>&lt;RangeFilter/&gt;</b>','LuceneContribQuery.dtd.html#RangeFilter',false,false)
eltTree.linkNodes('30','31')
eltTree.addNode('32','@includeLower','LuceneContribQuery.dtd.html#RangeFilter_includeLower',false,false)
eltTree.linkNodes('30','32')
eltTree.addNode('33','@includeUpper','LuceneContribQuery.dtd.html#RangeFilter_includeUpper',false,false)
eltTree.linkNodes('30','33')
eltTree.addNode('34','<b>@lowerTerm</b>','LuceneContribQuery.dtd.html#RangeFilter_lowerTerm',false,false)
eltTree.linkNodes('30','34')
eltTree.addNode('35','<b>@upperTerm</b>','LuceneContribQuery.dtd.html#RangeFilter_upperTerm',false,false)
eltTree.linkNodes('30','35')
eltTree.addNode('36','<b>CachedFilter</b>','LuceneContribQuery.dtd.html#CachedFilter',false,false)
eltTree.linkNodes('29','36')
eltTree.addNode('37','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('36','37')
eltTree.linkNodes('37','6','<b>BooleanQuery</b>')
eltTree.linkNodes('37','12','<b>UserQuery</b>')
eltTree.linkNodes('37','14','<b>FilteredQuery</b>')
eltTree.linkNodes('37','18','<b>TermQuery</b>')
eltTree.linkNodes('37','21','<b>TermsQuery</b>')
eltTree.linkNodes('37','26','<b>MatchAllDocsQuery</b>')
eltTree.linkNodes('37','27','<b>ConstantScoreQuery</b>')
eltTree.addNode('38','<b>SpanOr</b>','LuceneContribQuery.dtd.html#SpanOr',false,false)
eltTree.addNode('32','@fieldName','LuceneContribQuery.dtd.html#RangeFilter_fieldName',false,false)
eltTree.linkNodes('31','32')
eltTree.addNode('33','@includeLower','LuceneContribQuery.dtd.html#RangeFilter_includeLower',false,false)
eltTree.linkNodes('31','33')
eltTree.addNode('34','@includeUpper','LuceneContribQuery.dtd.html#RangeFilter_includeUpper',false,false)
eltTree.linkNodes('31','34')
eltTree.addNode('35','<b>@lowerTerm</b>','LuceneContribQuery.dtd.html#RangeFilter_lowerTerm',false,false)
eltTree.linkNodes('31','35')
eltTree.addNode('36','<b>@upperTerm</b>','LuceneContribQuery.dtd.html#RangeFilter_upperTerm',false,false)
eltTree.linkNodes('31','36')
eltTree.addNode('37','<b>CachedFilter</b>','LuceneContribQuery.dtd.html#CachedFilter',false,false)
eltTree.linkNodes('30','37')
eltTree.addNode('38','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('37','38')
eltTree.addNode('39','<i>&lt;choice&gt;*</i>',null,true,false)
eltTree.linkNodes('38','6','<b>BooleanQuery</b>')
eltTree.linkNodes('38','12','<b>UserQuery</b>')
eltTree.linkNodes('38','15','<b>FilteredQuery</b>')
eltTree.linkNodes('38','19','<b>TermQuery</b>')
eltTree.linkNodes('38','22','<b>TermsQuery</b>')
eltTree.linkNodes('38','27','<b>MatchAllDocsQuery</b>')
eltTree.linkNodes('38','28','<b>ConstantScoreQuery</b>')
eltTree.addNode('39','<b>SpanOr</b>','LuceneContribQuery.dtd.html#SpanOr',false,false)
eltTree.linkNodes('38','39')
eltTree.linkNodes('39','38','<b>SpanOr</b>')
eltTree.addNode('40','<b>SpanNear</b>','LuceneContribQuery.dtd.html#SpanNear',false,false)
eltTree.addNode('40','<i>&lt;choice&gt;*</i>',null,true,false)
eltTree.linkNodes('39','40')
eltTree.addNode('41','@inOrder','LuceneContribQuery.dtd.html#SpanNear_inOrder',false,false)
eltTree.linkNodes('40','39','<b>SpanOr</b>')
eltTree.addNode('41','<b>SpanNear</b>','LuceneContribQuery.dtd.html#SpanNear',false,false)
eltTree.linkNodes('40','41')
eltTree.addNode('42','<b>@slop</b>','LuceneContribQuery.dtd.html#SpanNear_slop',false,false)
eltTree.linkNodes('40','42')
eltTree.addNode('43','<i>&lt;choice&gt;*</i>',null,true,false)
eltTree.linkNodes('40','43')
eltTree.linkNodes('43','38','<b>SpanOr</b>')
eltTree.linkNodes('43','40','<b>SpanNear</b>')
eltTree.addNode('44','<b>SpanOrTerms</b>','LuceneContribQuery.dtd.html#SpanOrTerms',false,false)
eltTree.linkNodes('43','44')
eltTree.addNode('45','<b>@fieldName</b>','LuceneContribQuery.dtd.html#SpanOrTerms_fieldName',false,false)
eltTree.addNode('42','@inOrder','LuceneContribQuery.dtd.html#SpanNear_inOrder',false,false)
eltTree.linkNodes('41','42')
eltTree.addNode('43','<b>@slop</b>','LuceneContribQuery.dtd.html#SpanNear_slop',false,false)
eltTree.linkNodes('41','43')
eltTree.addNode('44','<i>&lt;choice&gt;*</i>',null,true,false)
eltTree.linkNodes('41','44')
eltTree.linkNodes('44','39','<b>SpanOr</b>')
eltTree.linkNodes('44','41','<b>SpanNear</b>')
eltTree.addNode('45','<b>SpanOrTerms</b>','LuceneContribQuery.dtd.html#SpanOrTerms',false,false)
eltTree.linkNodes('44','45')
eltTree.addNode('46','<b>SpanFirst</b>','LuceneContribQuery.dtd.html#SpanFirst',false,false)
eltTree.linkNodes('43','46')
eltTree.addNode('47','@boost','LuceneContribQuery.dtd.html#SpanFirst_boost',false,false)
eltTree.linkNodes('46','47')
eltTree.addNode('48','<b>@end</b>','LuceneContribQuery.dtd.html#SpanFirst_end',false,false)
eltTree.linkNodes('46','48')
eltTree.addNode('49','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('46','49')
eltTree.linkNodes('49','38','<b>SpanOr</b>')
eltTree.linkNodes('49','40','<b>SpanNear</b>')
eltTree.linkNodes('49','44','<b>SpanOrTerms</b>')
eltTree.linkNodes('49','46','<b>SpanFirst</b>')
eltTree.addNode('50','<b>SpanNot</b>','LuceneContribQuery.dtd.html#SpanNot',false,false)
eltTree.linkNodes('49','50')
eltTree.addNode('51','<b>Include</b>','LuceneContribQuery.dtd.html#Include',false,false)
eltTree.addNode('46','<b>@fieldName</b>','LuceneContribQuery.dtd.html#SpanOrTerms_fieldName',false,false)
eltTree.linkNodes('45','46')
eltTree.addNode('47','<b>SpanFirst</b>','LuceneContribQuery.dtd.html#SpanFirst',false,false)
eltTree.linkNodes('44','47')
eltTree.addNode('48','@boost','LuceneContribQuery.dtd.html#SpanFirst_boost',false,false)
eltTree.linkNodes('47','48')
eltTree.addNode('49','<b>@end</b>','LuceneContribQuery.dtd.html#SpanFirst_end',false,false)
eltTree.linkNodes('47','49')
eltTree.addNode('50','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('47','50')
eltTree.linkNodes('50','39','<b>SpanOr</b>')
eltTree.linkNodes('50','41','<b>SpanNear</b>')
eltTree.linkNodes('50','45','<b>SpanOrTerms</b>')
eltTree.linkNodes('50','47','<b>SpanFirst</b>')
eltTree.addNode('51','<b>SpanNot</b>','LuceneContribQuery.dtd.html#SpanNot',false,false)
eltTree.linkNodes('50','51')
eltTree.addNode('52','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.addNode('52','<b>Include</b>','LuceneContribQuery.dtd.html#Include',false,false)
eltTree.linkNodes('51','52')
eltTree.linkNodes('52','38','<b>SpanOr</b>')
eltTree.linkNodes('52','40','<b>SpanNear</b>')
eltTree.linkNodes('52','44','<b>SpanOrTerms</b>')
eltTree.linkNodes('52','46','<b>SpanFirst</b>')
eltTree.linkNodes('52','50','<b>SpanNot</b>')
eltTree.addNode('53','<b>SpanTerm</b>','LuceneContribQuery.dtd.html#SpanTerm',false,false)
eltTree.addNode('53','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('52','53')
eltTree.addNode('54','<b>@fieldName</b>','LuceneContribQuery.dtd.html#SpanTerm_fieldName',false,false)
eltTree.linkNodes('53','39','<b>SpanOr</b>')
eltTree.linkNodes('53','41','<b>SpanNear</b>')
eltTree.linkNodes('53','45','<b>SpanOrTerms</b>')
eltTree.linkNodes('53','47','<b>SpanFirst</b>')
eltTree.linkNodes('53','51','<b>SpanNot</b>')
eltTree.addNode('54','<b>SpanTerm</b>','LuceneContribQuery.dtd.html#SpanTerm',false,false)
eltTree.linkNodes('53','54')
eltTree.addNode('55','<b>Exclude</b>','LuceneContribQuery.dtd.html#Exclude',false,false)
eltTree.linkNodes('50','55')
eltTree.addNode('56','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('55','56')
eltTree.linkNodes('56','38','<b>SpanOr</b>')
eltTree.linkNodes('56','40','<b>SpanNear</b>')
eltTree.linkNodes('56','44','<b>SpanOrTerms</b>')
eltTree.linkNodes('56','46','<b>SpanFirst</b>')
eltTree.linkNodes('56','50','<b>SpanNot</b>')
eltTree.linkNodes('56','53','<b>SpanTerm</b>')
eltTree.linkNodes('49','53','<b>SpanTerm</b>')
eltTree.linkNodes('43','50','<b>SpanNot</b>')
eltTree.linkNodes('43','53','<b>SpanTerm</b>')
eltTree.linkNodes('39','44','<b>SpanOrTerms</b>')
eltTree.linkNodes('39','46','<b>SpanFirst</b>')
eltTree.linkNodes('39','50','<b>SpanNot</b>')
eltTree.linkNodes('39','53','<b>SpanTerm</b>')
eltTree.linkNodes('37','40','<b>SpanNear</b>')
eltTree.linkNodes('37','44','<b>SpanOrTerms</b>')
eltTree.linkNodes('37','46','<b>SpanFirst</b>')
eltTree.linkNodes('37','50','<b>SpanNot</b>')
eltTree.linkNodes('37','53','<b>SpanTerm</b>')
eltTree.addNode('57','<b>LikeThisQuery</b>','LuceneContribQuery.dtd.html#LikeThisQuery',false,false)
eltTree.linkNodes('37','57')
eltTree.addNode('58','@boost','LuceneContribQuery.dtd.html#LikeThisQuery_boost',false,false)
eltTree.linkNodes('57','58')
eltTree.addNode('59','@fieldNames','LuceneContribQuery.dtd.html#LikeThisQuery_fieldNames',false,false)
eltTree.linkNodes('57','59')
eltTree.addNode('60','@maxQueryTerms','LuceneContribQuery.dtd.html#LikeThisQuery_maxQueryTerms',false,false)
eltTree.linkNodes('57','60')
eltTree.addNode('61','@minTermFrequency','LuceneContribQuery.dtd.html#LikeThisQuery_minTermFrequency',false,false)
eltTree.linkNodes('57','61')
eltTree.addNode('62','@percentTermsToMatch','LuceneContribQuery.dtd.html#LikeThisQuery_percentTermsToMatch',false,false)
eltTree.linkNodes('57','62')
eltTree.addNode('63','@stopWords','LuceneContribQuery.dtd.html#LikeThisQuery_stopWords',false,false)
eltTree.linkNodes('57','63')
eltTree.addNode('64','<b>BoostingQuery</b>','LuceneContribQuery.dtd.html#BoostingQuery',false,false)
eltTree.linkNodes('37','64')
eltTree.addNode('65','@boost','LuceneContribQuery.dtd.html#BoostingQuery_boost',false,false)
eltTree.linkNodes('64','65')
eltTree.linkNodes('64','16','<b>Query</b>')
eltTree.addNode('66','<b>BoostQuery</b>','LuceneContribQuery.dtd.html#BoostQuery',false,false)
eltTree.linkNodes('64','66')
eltTree.addNode('67','@boost','LuceneContribQuery.dtd.html#BoostQuery_boost',false,false)
eltTree.linkNodes('66','67')
eltTree.addNode('68','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('66','68')
eltTree.linkNodes('68','6','<b>BooleanQuery</b>')
eltTree.linkNodes('68','12','<b>UserQuery</b>')
eltTree.linkNodes('68','14','<b>FilteredQuery</b>')
eltTree.linkNodes('68','18','<b>TermQuery</b>')
eltTree.linkNodes('68','21','<b>TermsQuery</b>')
eltTree.linkNodes('68','26','<b>MatchAllDocsQuery</b>')
eltTree.linkNodes('68','27','<b>ConstantScoreQuery</b>')
eltTree.linkNodes('68','38','<b>SpanOr</b>')
eltTree.linkNodes('68','40','<b>SpanNear</b>')
eltTree.linkNodes('68','44','<b>SpanOrTerms</b>')
eltTree.linkNodes('68','46','<b>SpanFirst</b>')
eltTree.linkNodes('68','50','<b>SpanNot</b>')
eltTree.linkNodes('68','53','<b>SpanTerm</b>')
eltTree.linkNodes('68','57','<b>LikeThisQuery</b>')
eltTree.linkNodes('68','64','<b>BoostingQuery</b>')
eltTree.addNode('69','<b>FuzzyLikeThisQuery</b>','LuceneContribQuery.dtd.html#FuzzyLikeThisQuery',false,false)
eltTree.linkNodes('68','69')
eltTree.addNode('70','@boost','LuceneContribQuery.dtd.html#FuzzyLikeThisQuery_boost',false,false)
eltTree.addNode('55','<b>@fieldName</b>','LuceneContribQuery.dtd.html#SpanTerm_fieldName',false,false)
eltTree.linkNodes('54','55')
eltTree.addNode('56','<b>Exclude</b>','LuceneContribQuery.dtd.html#Exclude',false,false)
eltTree.linkNodes('51','56')
eltTree.addNode('57','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('56','57')
eltTree.linkNodes('57','39','<b>SpanOr</b>')
eltTree.linkNodes('57','41','<b>SpanNear</b>')
eltTree.linkNodes('57','45','<b>SpanOrTerms</b>')
eltTree.linkNodes('57','47','<b>SpanFirst</b>')
eltTree.linkNodes('57','51','<b>SpanNot</b>')
eltTree.linkNodes('57','54','<b>SpanTerm</b>')
eltTree.linkNodes('50','54','<b>SpanTerm</b>')
eltTree.linkNodes('44','51','<b>SpanNot</b>')
eltTree.linkNodes('44','54','<b>SpanTerm</b>')
eltTree.linkNodes('40','45','<b>SpanOrTerms</b>')
eltTree.linkNodes('40','47','<b>SpanFirst</b>')
eltTree.linkNodes('40','51','<b>SpanNot</b>')
eltTree.linkNodes('40','54','<b>SpanTerm</b>')
eltTree.linkNodes('38','41','<b>SpanNear</b>')
eltTree.linkNodes('38','45','<b>SpanOrTerms</b>')
eltTree.linkNodes('38','47','<b>SpanFirst</b>')
eltTree.linkNodes('38','51','<b>SpanNot</b>')
eltTree.linkNodes('38','54','<b>SpanTerm</b>')
eltTree.addNode('58','<b>LikeThisQuery</b>','LuceneContribQuery.dtd.html#LikeThisQuery',false,false)
eltTree.linkNodes('38','58')
eltTree.addNode('59','@boost','LuceneContribQuery.dtd.html#LikeThisQuery_boost',false,false)
eltTree.linkNodes('58','59')
eltTree.addNode('60','@fieldNames','LuceneContribQuery.dtd.html#LikeThisQuery_fieldNames',false,false)
eltTree.linkNodes('58','60')
eltTree.addNode('61','@maxQueryTerms','LuceneContribQuery.dtd.html#LikeThisQuery_maxQueryTerms',false,false)
eltTree.linkNodes('58','61')
eltTree.addNode('62','@minTermFrequency','LuceneContribQuery.dtd.html#LikeThisQuery_minTermFrequency',false,false)
eltTree.linkNodes('58','62')
eltTree.addNode('63','@percentTermsToMatch','LuceneContribQuery.dtd.html#LikeThisQuery_percentTermsToMatch',false,false)
eltTree.linkNodes('58','63')
eltTree.addNode('64','@stopWords','LuceneContribQuery.dtd.html#LikeThisQuery_stopWords',false,false)
eltTree.linkNodes('58','64')
eltTree.addNode('65','<b>BoostingQuery</b>','LuceneContribQuery.dtd.html#BoostingQuery',false,false)
eltTree.linkNodes('38','65')
eltTree.addNode('66','@boost','LuceneContribQuery.dtd.html#BoostingQuery_boost',false,false)
eltTree.linkNodes('65','66')
eltTree.linkNodes('65','17','<b>Query</b>')
eltTree.addNode('67','<b>BoostQuery</b>','LuceneContribQuery.dtd.html#BoostQuery',false,false)
eltTree.linkNodes('65','67')
eltTree.addNode('68','@boost','LuceneContribQuery.dtd.html#BoostQuery_boost',false,false)
eltTree.linkNodes('67','68')
eltTree.addNode('69','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('67','69')
eltTree.linkNodes('69','6','<b>BooleanQuery</b>')
eltTree.linkNodes('69','12','<b>UserQuery</b>')
eltTree.linkNodes('69','15','<b>FilteredQuery</b>')
eltTree.linkNodes('69','19','<b>TermQuery</b>')
eltTree.linkNodes('69','22','<b>TermsQuery</b>')
eltTree.linkNodes('69','27','<b>MatchAllDocsQuery</b>')
eltTree.linkNodes('69','28','<b>ConstantScoreQuery</b>')
eltTree.linkNodes('69','39','<b>SpanOr</b>')
eltTree.linkNodes('69','41','<b>SpanNear</b>')
eltTree.linkNodes('69','45','<b>SpanOrTerms</b>')
eltTree.linkNodes('69','47','<b>SpanFirst</b>')
eltTree.linkNodes('69','51','<b>SpanNot</b>')
eltTree.linkNodes('69','54','<b>SpanTerm</b>')
eltTree.linkNodes('69','58','<b>LikeThisQuery</b>')
eltTree.linkNodes('69','65','<b>BoostingQuery</b>')
eltTree.addNode('70','<b>FuzzyLikeThisQuery</b>','LuceneContribQuery.dtd.html#FuzzyLikeThisQuery',false,false)
eltTree.linkNodes('69','70')
eltTree.addNode('71','@ignoreTF','LuceneContribQuery.dtd.html#FuzzyLikeThisQuery_ignoreTF',false,false)
eltTree.linkNodes('69','71')
eltTree.addNode('72','@maxNumTerms','LuceneContribQuery.dtd.html#FuzzyLikeThisQuery_maxNumTerms',false,false)
eltTree.linkNodes('69','72')
eltTree.addNode('73','<i>&lt;sequence&gt;*</i>',null,true,false)
eltTree.linkNodes('69','73')
eltTree.addNode('74','<b>Field</b>','LuceneContribQuery.dtd.html#Field',false,false)
eltTree.linkNodes('73','74')
eltTree.addNode('75','@fieldName','LuceneContribQuery.dtd.html#Field_fieldName',false,false)
eltTree.addNode('71','@boost','LuceneContribQuery.dtd.html#FuzzyLikeThisQuery_boost',false,false)
eltTree.linkNodes('70','71')
eltTree.addNode('72','@ignoreTF','LuceneContribQuery.dtd.html#FuzzyLikeThisQuery_ignoreTF',false,false)
eltTree.linkNodes('70','72')
eltTree.addNode('73','@maxNumTerms','LuceneContribQuery.dtd.html#FuzzyLikeThisQuery_maxNumTerms',false,false)
eltTree.linkNodes('70','73')
eltTree.addNode('74','<i>&lt;sequence&gt;*</i>',null,true,false)
eltTree.linkNodes('70','74')
eltTree.addNode('75','<b>Field</b>','LuceneContribQuery.dtd.html#Field',false,false)
eltTree.linkNodes('74','75')
eltTree.addNode('76','@minSimilarity','LuceneContribQuery.dtd.html#Field_minSimilarity',false,false)
eltTree.linkNodes('74','76')
eltTree.addNode('77','@prefixLength','LuceneContribQuery.dtd.html#Field_prefixLength',false,false)
eltTree.linkNodes('74','77')
eltTree.linkNodes('37','69','<b>FuzzyLikeThisQuery</b>')
eltTree.linkNodes('37','30','<b>RangeFilter</b>')
eltTree.linkNodes('37','36','<b>CachedFilter</b>')
eltTree.addNode('78','<b>TermsFilter</b>','LuceneContribQuery.dtd.html#TermsFilter',false,false)
eltTree.linkNodes('37','78')
eltTree.addNode('79','@fieldName','LuceneContribQuery.dtd.html#TermsFilter_fieldName',false,false)
eltTree.linkNodes('78','79')
eltTree.linkNodes('37','1','<b>BooleanFilter</b>')
eltTree.addNode('80','<b>&lt;DuplicateFilter/&gt;</b>','LuceneContribQuery.dtd.html#DuplicateFilter',false,false)
eltTree.linkNodes('37','80')
eltTree.addNode('81','@fieldName','LuceneContribQuery.dtd.html#DuplicateFilter_fieldName',false,false)
eltTree.linkNodes('80','81')
eltTree.addNode('82','@keepMode','LuceneContribQuery.dtd.html#DuplicateFilter_keepMode',false,false)
eltTree.linkNodes('80','82')
eltTree.addNode('83','@processingMode','LuceneContribQuery.dtd.html#DuplicateFilter_processingMode',false,false)
eltTree.linkNodes('80','83')
eltTree.linkNodes('29','78','<b>TermsFilter</b>')
eltTree.linkNodes('29','1','<b>BooleanFilter</b>')
eltTree.linkNodes('29','80','<b>DuplicateFilter</b>')
eltTree.linkNodes('17','38','<b>SpanOr</b>')
eltTree.linkNodes('17','40','<b>SpanNear</b>')
eltTree.linkNodes('17','44','<b>SpanOrTerms</b>')
eltTree.linkNodes('17','46','<b>SpanFirst</b>')
eltTree.linkNodes('17','50','<b>SpanNot</b>')
eltTree.linkNodes('17','53','<b>SpanTerm</b>')
eltTree.linkNodes('17','57','<b>LikeThisQuery</b>')
eltTree.linkNodes('17','64','<b>BoostingQuery</b>')
eltTree.linkNodes('17','69','<b>FuzzyLikeThisQuery</b>')
eltTree.addNode('84','<b>Filter</b>','LuceneContribQuery.dtd.html#Filter',false,false)
eltTree.linkNodes('14','84')
eltTree.addNode('85','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('84','85')
eltTree.linkNodes('85','30','<b>RangeFilter</b>')
eltTree.linkNodes('85','36','<b>CachedFilter</b>')
eltTree.linkNodes('85','78','<b>TermsFilter</b>')
eltTree.linkNodes('85','1','<b>BooleanFilter</b>')
eltTree.linkNodes('85','80','<b>DuplicateFilter</b>')
eltTree.linkNodes('5','18','<b>TermQuery</b>')
eltTree.linkNodes('5','21','<b>TermsQuery</b>')
eltTree.linkNodes('5','26','<b>MatchAllDocsQuery</b>')
eltTree.linkNodes('5','27','<b>ConstantScoreQuery</b>')
eltTree.linkNodes('5','38','<b>SpanOr</b>')
eltTree.linkNodes('5','40','<b>SpanNear</b>')
eltTree.linkNodes('5','44','<b>SpanOrTerms</b>')
eltTree.linkNodes('5','46','<b>SpanFirst</b>')
eltTree.linkNodes('5','50','<b>SpanNot</b>')
eltTree.linkNodes('5','53','<b>SpanTerm</b>')
eltTree.linkNodes('5','57','<b>LikeThisQuery</b>')
eltTree.linkNodes('5','64','<b>BoostingQuery</b>')
eltTree.linkNodes('5','69','<b>FuzzyLikeThisQuery</b>')
eltTree.linkNodes('5','30','<b>RangeFilter</b>')
eltTree.linkNodes('5','36','<b>CachedFilter</b>')
eltTree.linkNodes('5','78','<b>TermsFilter</b>')
eltTree.addNode('76','@fieldName','LuceneContribQuery.dtd.html#Field_fieldName',false,false)
eltTree.linkNodes('75','76')
eltTree.addNode('77','@minSimilarity','LuceneContribQuery.dtd.html#Field_minSimilarity',false,false)
eltTree.linkNodes('75','77')
eltTree.addNode('78','@prefixLength','LuceneContribQuery.dtd.html#Field_prefixLength',false,false)
eltTree.linkNodes('75','78')
eltTree.linkNodes('38','70','<b>FuzzyLikeThisQuery</b>')
eltTree.linkNodes('38','31','<b>RangeFilter</b>')
eltTree.linkNodes('38','37','<b>CachedFilter</b>')
eltTree.addNode('79','<b>TermsFilter</b>','LuceneContribQuery.dtd.html#TermsFilter',false,false)
eltTree.linkNodes('38','79')
eltTree.addNode('80','@fieldName','LuceneContribQuery.dtd.html#TermsFilter_fieldName',false,false)
eltTree.linkNodes('79','80')
eltTree.linkNodes('38','1','<b>BooleanFilter</b>')
eltTree.addNode('81','<b>&lt;DuplicateFilter/&gt;</b>','LuceneContribQuery.dtd.html#DuplicateFilter',false,false)
eltTree.linkNodes('38','81')
eltTree.addNode('82','@fieldName','LuceneContribQuery.dtd.html#DuplicateFilter_fieldName',false,false)
eltTree.linkNodes('81','82')
eltTree.addNode('83','@keepMode','LuceneContribQuery.dtd.html#DuplicateFilter_keepMode',false,false)
eltTree.linkNodes('81','83')
eltTree.addNode('84','@processingMode','LuceneContribQuery.dtd.html#DuplicateFilter_processingMode',false,false)
eltTree.linkNodes('81','84')
eltTree.linkNodes('30','79','<b>TermsFilter</b>')
eltTree.linkNodes('30','1','<b>BooleanFilter</b>')
eltTree.linkNodes('30','81','<b>DuplicateFilter</b>')
eltTree.linkNodes('18','39','<b>SpanOr</b>')
eltTree.linkNodes('18','41','<b>SpanNear</b>')
eltTree.linkNodes('18','45','<b>SpanOrTerms</b>')
eltTree.linkNodes('18','47','<b>SpanFirst</b>')
eltTree.linkNodes('18','51','<b>SpanNot</b>')
eltTree.linkNodes('18','54','<b>SpanTerm</b>')
eltTree.linkNodes('18','58','<b>LikeThisQuery</b>')
eltTree.linkNodes('18','65','<b>BoostingQuery</b>')
eltTree.linkNodes('18','70','<b>FuzzyLikeThisQuery</b>')
eltTree.addNode('85','<b>Filter</b>','LuceneContribQuery.dtd.html#Filter',false,false)
eltTree.linkNodes('15','85')
eltTree.addNode('86','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('85','86')
eltTree.linkNodes('86','31','<b>RangeFilter</b>')
eltTree.linkNodes('86','37','<b>CachedFilter</b>')
eltTree.linkNodes('86','79','<b>TermsFilter</b>')
eltTree.linkNodes('86','1','<b>BooleanFilter</b>')
eltTree.linkNodes('86','81','<b>DuplicateFilter</b>')
eltTree.linkNodes('5','19','<b>TermQuery</b>')
eltTree.linkNodes('5','22','<b>TermsQuery</b>')
eltTree.linkNodes('5','27','<b>MatchAllDocsQuery</b>')
eltTree.linkNodes('5','28','<b>ConstantScoreQuery</b>')
eltTree.linkNodes('5','39','<b>SpanOr</b>')
eltTree.linkNodes('5','41','<b>SpanNear</b>')
eltTree.linkNodes('5','45','<b>SpanOrTerms</b>')
eltTree.linkNodes('5','47','<b>SpanFirst</b>')
eltTree.linkNodes('5','51','<b>SpanNot</b>')
eltTree.linkNodes('5','54','<b>SpanTerm</b>')
eltTree.linkNodes('5','58','<b>LikeThisQuery</b>')
eltTree.linkNodes('5','65','<b>BoostingQuery</b>')
eltTree.linkNodes('5','70','<b>FuzzyLikeThisQuery</b>')
eltTree.linkNodes('5','31','<b>RangeFilter</b>')
eltTree.linkNodes('5','37','<b>CachedFilter</b>')
eltTree.linkNodes('5','79','<b>TermsFilter</b>')
eltTree.linkNodes('5','1','<b>BooleanFilter</b>')
eltTree.linkNodes('5','80','<b>DuplicateFilter</b>')
eltTree.linkNodes('5','81','<b>DuplicateFilter</b>')
eltTree.linkNodes('0','6','BooleanQuery')
eltTree.linkNodes('0','64','BoostingQuery')
eltTree.linkNodes('0','66','BoostQuery')
eltTree.linkNodes('0','36','CachedFilter')
eltTree.linkNodes('0','65','BoostingQuery')
eltTree.linkNodes('0','67','BoostQuery')
eltTree.linkNodes('0','37','CachedFilter')
eltTree.linkNodes('0','3','Clause')
eltTree.linkNodes('0','27','ConstantScoreQuery')
eltTree.linkNodes('0','80','DuplicateFilter')
eltTree.linkNodes('0','55','Exclude')
eltTree.linkNodes('0','74','Field')
eltTree.linkNodes('0','84','Filter')
eltTree.linkNodes('0','14','FilteredQuery')
eltTree.linkNodes('0','69','FuzzyLikeThisQuery')
eltTree.linkNodes('0','51','Include')
eltTree.linkNodes('0','57','LikeThisQuery')
eltTree.linkNodes('0','26','MatchAllDocsQuery')
eltTree.linkNodes('0','16','Query')
eltTree.linkNodes('0','30','RangeFilter')
eltTree.linkNodes('0','46','SpanFirst')
eltTree.linkNodes('0','40','SpanNear')
eltTree.linkNodes('0','50','SpanNot')
eltTree.linkNodes('0','38','SpanOr')
eltTree.linkNodes('0','44','SpanOrTerms')
eltTree.linkNodes('0','53','SpanTerm')
eltTree.linkNodes('0','18','TermQuery')
eltTree.linkNodes('0','78','TermsFilter')
eltTree.linkNodes('0','21','TermsQuery')
eltTree.linkNodes('0','28','ConstantScoreQuery')
eltTree.linkNodes('0','81','DuplicateFilter')
eltTree.linkNodes('0','56','Exclude')
eltTree.linkNodes('0','75','Field')
eltTree.linkNodes('0','85','Filter')
eltTree.linkNodes('0','15','FilteredQuery')
eltTree.linkNodes('0','70','FuzzyLikeThisQuery')
eltTree.linkNodes('0','52','Include')
eltTree.linkNodes('0','58','LikeThisQuery')
eltTree.linkNodes('0','27','MatchAllDocsQuery')
eltTree.linkNodes('0','17','Query')
eltTree.linkNodes('0','31','RangeFilter')
eltTree.linkNodes('0','47','SpanFirst')
eltTree.linkNodes('0','41','SpanNear')
eltTree.linkNodes('0','51','SpanNot')
eltTree.linkNodes('0','39','SpanOr')
eltTree.linkNodes('0','45','SpanOrTerms')
eltTree.linkNodes('0','54','SpanTerm')
eltTree.linkNodes('0','19','TermQuery')
eltTree.linkNodes('0','79','TermsFilter')
eltTree.linkNodes('0','22','TermsQuery')
eltTree.linkNodes('0','12','UserQuery')
eltTree.addRootNode('86','Core Lucene','LuceneCoreQuery.dtd.html',false,false)
eltTree.addNode('87','BooleanQuery','LuceneCoreQuery.dtd.html#BooleanQuery',false,false)
eltTree.linkNodes('86','87')
eltTree.addNode('88','@boost','LuceneCoreQuery.dtd.html#BooleanQuery_boost',false,false)
eltTree.addRootNode('87','Core Lucene','LuceneCoreQuery.dtd.html',false,false)
eltTree.addNode('88','BooleanQuery','LuceneCoreQuery.dtd.html#BooleanQuery',false,false)
eltTree.linkNodes('87','88')
eltTree.addNode('89','@disableCoord','LuceneCoreQuery.dtd.html#BooleanQuery_disableCoord',false,false)
eltTree.linkNodes('87','89')
eltTree.addNode('90','@fieldName','LuceneCoreQuery.dtd.html#BooleanQuery_fieldName',false,false)
eltTree.linkNodes('87','90')
eltTree.addNode('91','@minimumNumberShouldMatch','LuceneCoreQuery.dtd.html#BooleanQuery_minimumNumberShouldMatch',false,false)
eltTree.linkNodes('87','91')
eltTree.addNode('92','<b><i>&lt;sequence&gt;+</i></b>',null,true,false)
eltTree.linkNodes('87','92')
eltTree.addNode('93','<b>Clause</b>','LuceneCoreQuery.dtd.html#Clause',false,false)
eltTree.linkNodes('92','93')
eltTree.addNode('94','@occurs','LuceneCoreQuery.dtd.html#Clause_occurs',false,false)
eltTree.addNode('89','@boost','LuceneCoreQuery.dtd.html#BooleanQuery_boost',false,false)
eltTree.linkNodes('88','89')
eltTree.addNode('90','@disableCoord','LuceneCoreQuery.dtd.html#BooleanQuery_disableCoord',false,false)
eltTree.linkNodes('88','90')
eltTree.addNode('91','@fieldName','LuceneCoreQuery.dtd.html#BooleanQuery_fieldName',false,false)
eltTree.linkNodes('88','91')
eltTree.addNode('92','@minimumNumberShouldMatch','LuceneCoreQuery.dtd.html#BooleanQuery_minimumNumberShouldMatch',false,false)
eltTree.linkNodes('88','92')
eltTree.addNode('93','<b><i>&lt;sequence&gt;+</i></b>',null,true,false)
eltTree.linkNodes('88','93')
eltTree.addNode('94','<b>Clause</b>','LuceneCoreQuery.dtd.html#Clause',false,false)
eltTree.linkNodes('93','94')
eltTree.addNode('95','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('93','95')
eltTree.linkNodes('95','87','<b>BooleanQuery</b>')
eltTree.addNode('96','<b>UserQuery</b>','LuceneCoreQuery.dtd.html#UserQuery',false,false)
eltTree.linkNodes('95','96')
eltTree.addNode('97','@boost','LuceneCoreQuery.dtd.html#UserQuery_boost',false,false)
eltTree.addNode('95','@occurs','LuceneCoreQuery.dtd.html#Clause_occurs',false,false)
eltTree.linkNodes('94','95')
eltTree.addNode('96','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('94','96')
eltTree.linkNodes('96','88','<b>BooleanQuery</b>')
eltTree.addNode('97','<b>UserQuery</b>','LuceneCoreQuery.dtd.html#UserQuery',false,false)
eltTree.linkNodes('96','97')
eltTree.addNode('98','<b>FilteredQuery</b>','LuceneCoreQuery.dtd.html#FilteredQuery',false,false)
eltTree.linkNodes('95','98')
eltTree.addNode('99','@boost','LuceneCoreQuery.dtd.html#FilteredQuery_boost',false,false)
eltTree.linkNodes('98','99')
eltTree.addNode('100','<b>Query</b>','LuceneCoreQuery.dtd.html#Query',false,false)
eltTree.linkNodes('98','100')
eltTree.addNode('101','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.addNode('98','@boost','LuceneCoreQuery.dtd.html#UserQuery_boost',false,false)
eltTree.linkNodes('97','98')
eltTree.addNode('99','@fieldName','LuceneCoreQuery.dtd.html#UserQuery_fieldName',false,false)
eltTree.linkNodes('97','99')
eltTree.addNode('100','<b>FilteredQuery</b>','LuceneCoreQuery.dtd.html#FilteredQuery',false,false)
eltTree.linkNodes('96','100')
eltTree.addNode('101','@boost','LuceneCoreQuery.dtd.html#FilteredQuery_boost',false,false)
eltTree.linkNodes('100','101')
eltTree.linkNodes('101','87','<b>BooleanQuery</b>')
eltTree.linkNodes('101','96','<b>UserQuery</b>')
eltTree.linkNodes('101','98','<b>FilteredQuery</b>')
eltTree.addNode('102','<b>TermQuery</b>','LuceneCoreQuery.dtd.html#TermQuery',false,false)
eltTree.linkNodes('101','102')
eltTree.addNode('103','@boost','LuceneCoreQuery.dtd.html#TermQuery_boost',false,false)
eltTree.addNode('102','<b>Query</b>','LuceneCoreQuery.dtd.html#Query',false,false)
eltTree.linkNodes('100','102')
eltTree.addNode('103','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('102','103')
eltTree.addNode('104','@fieldName','LuceneCoreQuery.dtd.html#TermQuery_fieldName',false,false)
eltTree.linkNodes('102','104')
eltTree.addNode('105','<b>TermsQuery</b>','LuceneCoreQuery.dtd.html#TermsQuery',false,false)
eltTree.linkNodes('101','105')
eltTree.addNode('106','@boost','LuceneCoreQuery.dtd.html#TermsQuery_boost',false,false)
eltTree.linkNodes('105','106')
eltTree.addNode('107','@disableCoord','LuceneCoreQuery.dtd.html#TermsQuery_disableCoord',false,false)
eltTree.linkNodes('105','107')
eltTree.addNode('108','@fieldName','LuceneCoreQuery.dtd.html#TermsQuery_fieldName',false,false)
eltTree.linkNodes('105','108')
eltTree.addNode('109','@minimumNumberShouldMatch','LuceneCoreQuery.dtd.html#TermsQuery_minimumNumberShouldMatch',false,false)
eltTree.linkNodes('105','109')
eltTree.addNode('110','<b>&lt;MatchAllDocsQuery/&gt;</b>','LuceneCoreQuery.dtd.html#MatchAllDocsQuery',false,false)
eltTree.linkNodes('101','110')
eltTree.addNode('111','<b>ConstantScoreQuery</b>','LuceneCoreQuery.dtd.html#ConstantScoreQuery',false,false)
eltTree.linkNodes('101','111')
eltTree.addNode('112','@boost','LuceneCoreQuery.dtd.html#ConstantScoreQuery_boost',false,false)
eltTree.linkNodes('111','112')
eltTree.addNode('113','<i>&lt;choice&gt;*</i>',null,true,false)
eltTree.linkNodes('111','113')
eltTree.addNode('114','<b>&lt;RangeFilter/&gt;</b>','LuceneCoreQuery.dtd.html#RangeFilter',false,false)
eltTree.linkNodes('103','88','<b>BooleanQuery</b>')
eltTree.linkNodes('103','97','<b>UserQuery</b>')
eltTree.linkNodes('103','100','<b>FilteredQuery</b>')
eltTree.addNode('104','<b>TermQuery</b>','LuceneCoreQuery.dtd.html#TermQuery',false,false)
eltTree.linkNodes('103','104')
eltTree.addNode('105','@boost','LuceneCoreQuery.dtd.html#TermQuery_boost',false,false)
eltTree.linkNodes('104','105')
eltTree.addNode('106','@fieldName','LuceneCoreQuery.dtd.html#TermQuery_fieldName',false,false)
eltTree.linkNodes('104','106')
eltTree.addNode('107','<b>TermsQuery</b>','LuceneCoreQuery.dtd.html#TermsQuery',false,false)
eltTree.linkNodes('103','107')
eltTree.addNode('108','@boost','LuceneCoreQuery.dtd.html#TermsQuery_boost',false,false)
eltTree.linkNodes('107','108')
eltTree.addNode('109','@disableCoord','LuceneCoreQuery.dtd.html#TermsQuery_disableCoord',false,false)
eltTree.linkNodes('107','109')
eltTree.addNode('110','@fieldName','LuceneCoreQuery.dtd.html#TermsQuery_fieldName',false,false)
eltTree.linkNodes('107','110')
eltTree.addNode('111','@minimumNumberShouldMatch','LuceneCoreQuery.dtd.html#TermsQuery_minimumNumberShouldMatch',false,false)
eltTree.linkNodes('107','111')
eltTree.addNode('112','<b>&lt;MatchAllDocsQuery/&gt;</b>','LuceneCoreQuery.dtd.html#MatchAllDocsQuery',false,false)
eltTree.linkNodes('103','112')
eltTree.addNode('113','<b>ConstantScoreQuery</b>','LuceneCoreQuery.dtd.html#ConstantScoreQuery',false,false)
eltTree.linkNodes('103','113')
eltTree.addNode('114','@boost','LuceneCoreQuery.dtd.html#ConstantScoreQuery_boost',false,false)
eltTree.linkNodes('113','114')
eltTree.addNode('115','@fieldName','LuceneCoreQuery.dtd.html#RangeFilter_fieldName',false,false)
eltTree.linkNodes('114','115')
eltTree.addNode('116','@includeLower','LuceneCoreQuery.dtd.html#RangeFilter_includeLower',false,false)
eltTree.linkNodes('114','116')
eltTree.addNode('117','@includeUpper','LuceneCoreQuery.dtd.html#RangeFilter_includeUpper',false,false)
eltTree.linkNodes('114','117')
eltTree.addNode('118','<b>@lowerTerm</b>','LuceneCoreQuery.dtd.html#RangeFilter_lowerTerm',false,false)
eltTree.linkNodes('114','118')
eltTree.addNode('119','<b>@upperTerm</b>','LuceneCoreQuery.dtd.html#RangeFilter_upperTerm',false,false)
eltTree.linkNodes('114','119')
eltTree.addNode('120','<b>CachedFilter</b>','LuceneCoreQuery.dtd.html#CachedFilter',false,false)
eltTree.linkNodes('113','120')
eltTree.addNode('121','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('120','121')
eltTree.linkNodes('121','87','<b>BooleanQuery</b>')
eltTree.linkNodes('121','96','<b>UserQuery</b>')
eltTree.linkNodes('121','98','<b>FilteredQuery</b>')
eltTree.linkNodes('121','102','<b>TermQuery</b>')
eltTree.linkNodes('121','105','<b>TermsQuery</b>')
eltTree.linkNodes('121','110','<b>MatchAllDocsQuery</b>')
eltTree.linkNodes('121','111','<b>ConstantScoreQuery</b>')
eltTree.addNode('122','<b>SpanOr</b>','LuceneCoreQuery.dtd.html#SpanOr',false,false)
eltTree.linkNodes('121','122')
eltTree.addNode('123','<i>&lt;choice&gt;*</i>',null,true,false)
eltTree.addNode('115','<i>&lt;choice&gt;*</i>',null,true,false)
eltTree.linkNodes('113','115')
eltTree.addNode('116','<b>&lt;RangeFilter/&gt;</b>','LuceneCoreQuery.dtd.html#RangeFilter',false,false)
eltTree.linkNodes('115','116')
eltTree.addNode('117','@fieldName','LuceneCoreQuery.dtd.html#RangeFilter_fieldName',false,false)
eltTree.linkNodes('116','117')
eltTree.addNode('118','@includeLower','LuceneCoreQuery.dtd.html#RangeFilter_includeLower',false,false)
eltTree.linkNodes('116','118')
eltTree.addNode('119','@includeUpper','LuceneCoreQuery.dtd.html#RangeFilter_includeUpper',false,false)
eltTree.linkNodes('116','119')
eltTree.addNode('120','<b>@lowerTerm</b>','LuceneCoreQuery.dtd.html#RangeFilter_lowerTerm',false,false)
eltTree.linkNodes('116','120')
eltTree.addNode('121','<b>@upperTerm</b>','LuceneCoreQuery.dtd.html#RangeFilter_upperTerm',false,false)
eltTree.linkNodes('116','121')
eltTree.addNode('122','<b>CachedFilter</b>','LuceneCoreQuery.dtd.html#CachedFilter',false,false)
eltTree.linkNodes('115','122')
eltTree.addNode('123','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('122','123')
eltTree.linkNodes('123','122','<b>SpanOr</b>')
eltTree.addNode('124','<b>SpanNear</b>','LuceneCoreQuery.dtd.html#SpanNear',false,false)
eltTree.linkNodes('123','88','<b>BooleanQuery</b>')
eltTree.linkNodes('123','97','<b>UserQuery</b>')
eltTree.linkNodes('123','100','<b>FilteredQuery</b>')
eltTree.linkNodes('123','104','<b>TermQuery</b>')
eltTree.linkNodes('123','107','<b>TermsQuery</b>')
eltTree.linkNodes('123','112','<b>MatchAllDocsQuery</b>')
eltTree.linkNodes('123','113','<b>ConstantScoreQuery</b>')
eltTree.addNode('124','<b>SpanOr</b>','LuceneCoreQuery.dtd.html#SpanOr',false,false)
eltTree.linkNodes('123','124')
eltTree.addNode('125','@inOrder','LuceneCoreQuery.dtd.html#SpanNear_inOrder',false,false)
eltTree.addNode('125','<i>&lt;choice&gt;*</i>',null,true,false)
eltTree.linkNodes('124','125')
eltTree.addNode('126','<b>@slop</b>','LuceneCoreQuery.dtd.html#SpanNear_slop',false,false)
eltTree.linkNodes('124','126')
eltTree.addNode('127','<i>&lt;choice&gt;*</i>',null,true,false)
eltTree.linkNodes('124','127')
eltTree.linkNodes('127','122','<b>SpanOr</b>')
eltTree.linkNodes('127','124','<b>SpanNear</b>')
eltTree.addNode('128','<b>SpanOrTerms</b>','LuceneCoreQuery.dtd.html#SpanOrTerms',false,false)
eltTree.linkNodes('127','128')
eltTree.addNode('129','<b>@fieldName</b>','LuceneCoreQuery.dtd.html#SpanOrTerms_fieldName',false,false)
eltTree.linkNodes('128','129')
eltTree.addNode('130','<b>SpanFirst</b>','LuceneCoreQuery.dtd.html#SpanFirst',false,false)
eltTree.linkNodes('127','130')
eltTree.addNode('131','@boost','LuceneCoreQuery.dtd.html#SpanFirst_boost',false,false)
eltTree.linkNodes('125','124','<b>SpanOr</b>')
eltTree.addNode('126','<b>SpanNear</b>','LuceneCoreQuery.dtd.html#SpanNear',false,false)
eltTree.linkNodes('125','126')
eltTree.addNode('127','@inOrder','LuceneCoreQuery.dtd.html#SpanNear_inOrder',false,false)
eltTree.linkNodes('126','127')
eltTree.addNode('128','<b>@slop</b>','LuceneCoreQuery.dtd.html#SpanNear_slop',false,false)
eltTree.linkNodes('126','128')
eltTree.addNode('129','<i>&lt;choice&gt;*</i>',null,true,false)
eltTree.linkNodes('126','129')
eltTree.linkNodes('129','124','<b>SpanOr</b>')
eltTree.linkNodes('129','126','<b>SpanNear</b>')
eltTree.addNode('130','<b>SpanOrTerms</b>','LuceneCoreQuery.dtd.html#SpanOrTerms',false,false)
eltTree.linkNodes('129','130')
eltTree.addNode('131','<b>@fieldName</b>','LuceneCoreQuery.dtd.html#SpanOrTerms_fieldName',false,false)
eltTree.linkNodes('130','131')
eltTree.addNode('132','<b>@end</b>','LuceneCoreQuery.dtd.html#SpanFirst_end',false,false)
eltTree.linkNodes('130','132')
eltTree.addNode('133','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('130','133')
eltTree.linkNodes('133','122','<b>SpanOr</b>')
eltTree.linkNodes('133','124','<b>SpanNear</b>')
eltTree.linkNodes('133','128','<b>SpanOrTerms</b>')
eltTree.linkNodes('133','130','<b>SpanFirst</b>')
eltTree.addNode('134','<b>SpanNot</b>','LuceneCoreQuery.dtd.html#SpanNot',false,false)
eltTree.linkNodes('133','134')
eltTree.addNode('135','<b>Include</b>','LuceneCoreQuery.dtd.html#Include',false,false)
eltTree.linkNodes('134','135')
eltTree.addNode('136','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.addNode('132','<b>SpanFirst</b>','LuceneCoreQuery.dtd.html#SpanFirst',false,false)
eltTree.linkNodes('129','132')
eltTree.addNode('133','@boost','LuceneCoreQuery.dtd.html#SpanFirst_boost',false,false)
eltTree.linkNodes('132','133')
eltTree.addNode('134','<b>@end</b>','LuceneCoreQuery.dtd.html#SpanFirst_end',false,false)
eltTree.linkNodes('132','134')
eltTree.addNode('135','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('132','135')
eltTree.linkNodes('135','124','<b>SpanOr</b>')
eltTree.linkNodes('135','126','<b>SpanNear</b>')
eltTree.linkNodes('135','130','<b>SpanOrTerms</b>')
eltTree.linkNodes('135','132','<b>SpanFirst</b>')
eltTree.addNode('136','<b>SpanNot</b>','LuceneCoreQuery.dtd.html#SpanNot',false,false)
eltTree.linkNodes('135','136')
eltTree.linkNodes('136','122','<b>SpanOr</b>')
eltTree.linkNodes('136','124','<b>SpanNear</b>')
eltTree.linkNodes('136','128','<b>SpanOrTerms</b>')
eltTree.linkNodes('136','130','<b>SpanFirst</b>')
eltTree.linkNodes('136','134','<b>SpanNot</b>')
eltTree.addNode('137','<b>SpanTerm</b>','LuceneCoreQuery.dtd.html#SpanTerm',false,false)
eltTree.addNode('137','<b>Include</b>','LuceneCoreQuery.dtd.html#Include',false,false)
eltTree.linkNodes('136','137')
eltTree.addNode('138','<b>@fieldName</b>','LuceneCoreQuery.dtd.html#SpanTerm_fieldName',false,false)
eltTree.addNode('138','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('137','138')
eltTree.addNode('139','<b>Exclude</b>','LuceneCoreQuery.dtd.html#Exclude',false,false)
eltTree.linkNodes('134','139')
eltTree.addNode('140','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('138','124','<b>SpanOr</b>')
eltTree.linkNodes('138','126','<b>SpanNear</b>')
eltTree.linkNodes('138','130','<b>SpanOrTerms</b>')
eltTree.linkNodes('138','132','<b>SpanFirst</b>')
eltTree.linkNodes('138','136','<b>SpanNot</b>')
eltTree.addNode('139','<b>SpanTerm</b>','LuceneCoreQuery.dtd.html#SpanTerm',false,false)
eltTree.linkNodes('138','139')
eltTree.addNode('140','<b>@fieldName</b>','LuceneCoreQuery.dtd.html#SpanTerm_fieldName',false,false)
eltTree.linkNodes('139','140')
eltTree.linkNodes('140','122','<b>SpanOr</b>')
eltTree.linkNodes('140','124','<b>SpanNear</b>')
eltTree.linkNodes('140','128','<b>SpanOrTerms</b>')
eltTree.linkNodes('140','130','<b>SpanFirst</b>')
eltTree.linkNodes('140','134','<b>SpanNot</b>')
eltTree.linkNodes('140','137','<b>SpanTerm</b>')
eltTree.linkNodes('133','137','<b>SpanTerm</b>')
eltTree.linkNodes('127','134','<b>SpanNot</b>')
eltTree.linkNodes('127','137','<b>SpanTerm</b>')
eltTree.linkNodes('123','128','<b>SpanOrTerms</b>')
eltTree.linkNodes('123','130','<b>SpanFirst</b>')
eltTree.linkNodes('123','134','<b>SpanNot</b>')
eltTree.linkNodes('123','137','<b>SpanTerm</b>')
eltTree.linkNodes('121','124','<b>SpanNear</b>')
eltTree.linkNodes('121','128','<b>SpanOrTerms</b>')
eltTree.linkNodes('121','130','<b>SpanFirst</b>')
eltTree.linkNodes('121','134','<b>SpanNot</b>')
eltTree.linkNodes('121','137','<b>SpanTerm</b>')
eltTree.linkNodes('121','114','<b>RangeFilter</b>')
eltTree.linkNodes('121','120','<b>CachedFilter</b>')
eltTree.linkNodes('101','122','<b>SpanOr</b>')
eltTree.linkNodes('101','124','<b>SpanNear</b>')
eltTree.linkNodes('101','128','<b>SpanOrTerms</b>')
eltTree.linkNodes('101','130','<b>SpanFirst</b>')
eltTree.linkNodes('101','134','<b>SpanNot</b>')
eltTree.linkNodes('101','137','<b>SpanTerm</b>')
eltTree.addNode('141','<b>Filter</b>','LuceneCoreQuery.dtd.html#Filter',false,false)
eltTree.linkNodes('98','141')
eltTree.addNode('141','<b>Exclude</b>','LuceneCoreQuery.dtd.html#Exclude',false,false)
eltTree.linkNodes('136','141')
eltTree.addNode('142','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('141','142')
eltTree.linkNodes('142','114','<b>RangeFilter</b>')
eltTree.linkNodes('142','120','<b>CachedFilter</b>')
eltTree.linkNodes('95','102','<b>TermQuery</b>')
eltTree.linkNodes('95','105','<b>TermsQuery</b>')
eltTree.linkNodes('95','110','<b>MatchAllDocsQuery</b>')
eltTree.linkNodes('95','111','<b>ConstantScoreQuery</b>')
eltTree.linkNodes('95','122','<b>SpanOr</b>')
eltTree.linkNodes('95','124','<b>SpanNear</b>')
eltTree.linkNodes('95','128','<b>SpanOrTerms</b>')
eltTree.linkNodes('95','130','<b>SpanFirst</b>')
eltTree.linkNodes('95','134','<b>SpanNot</b>')
eltTree.linkNodes('95','137','<b>SpanTerm</b>')
eltTree.linkNodes('95','114','<b>RangeFilter</b>')
eltTree.linkNodes('95','120','<b>CachedFilter</b>')
eltTree.linkNodes('86','120','CachedFilter')
eltTree.linkNodes('86','93','Clause')
eltTree.linkNodes('86','111','ConstantScoreQuery')
eltTree.linkNodes('86','139','Exclude')
eltTree.linkNodes('86','141','Filter')
eltTree.linkNodes('86','98','FilteredQuery')
eltTree.linkNodes('86','135','Include')
eltTree.linkNodes('86','110','MatchAllDocsQuery')
eltTree.linkNodes('86','100','Query')
eltTree.linkNodes('86','114','RangeFilter')
eltTree.linkNodes('86','130','SpanFirst')
eltTree.linkNodes('86','124','SpanNear')
eltTree.linkNodes('86','134','SpanNot')
eltTree.linkNodes('86','122','SpanOr')
eltTree.linkNodes('86','128','SpanOrTerms')
eltTree.linkNodes('86','137','SpanTerm')
eltTree.linkNodes('86','102','TermQuery')
eltTree.linkNodes('86','105','TermsQuery')
eltTree.linkNodes('86','96','UserQuery')
eltTree.linkNodes('142','124','<b>SpanOr</b>')
eltTree.linkNodes('142','126','<b>SpanNear</b>')
eltTree.linkNodes('142','130','<b>SpanOrTerms</b>')
eltTree.linkNodes('142','132','<b>SpanFirst</b>')
eltTree.linkNodes('142','136','<b>SpanNot</b>')
eltTree.linkNodes('142','139','<b>SpanTerm</b>')
eltTree.linkNodes('135','139','<b>SpanTerm</b>')
eltTree.linkNodes('129','136','<b>SpanNot</b>')
eltTree.linkNodes('129','139','<b>SpanTerm</b>')
eltTree.linkNodes('125','130','<b>SpanOrTerms</b>')
eltTree.linkNodes('125','132','<b>SpanFirst</b>')
eltTree.linkNodes('125','136','<b>SpanNot</b>')
eltTree.linkNodes('125','139','<b>SpanTerm</b>')
eltTree.linkNodes('123','126','<b>SpanNear</b>')
eltTree.linkNodes('123','130','<b>SpanOrTerms</b>')
eltTree.linkNodes('123','132','<b>SpanFirst</b>')
eltTree.linkNodes('123','136','<b>SpanNot</b>')
eltTree.linkNodes('123','139','<b>SpanTerm</b>')
eltTree.linkNodes('123','116','<b>RangeFilter</b>')
eltTree.linkNodes('123','122','<b>CachedFilter</b>')
eltTree.linkNodes('103','124','<b>SpanOr</b>')
eltTree.linkNodes('103','126','<b>SpanNear</b>')
eltTree.linkNodes('103','130','<b>SpanOrTerms</b>')
eltTree.linkNodes('103','132','<b>SpanFirst</b>')
eltTree.linkNodes('103','136','<b>SpanNot</b>')
eltTree.linkNodes('103','139','<b>SpanTerm</b>')
eltTree.addNode('143','<b>Filter</b>','LuceneCoreQuery.dtd.html#Filter',false,false)
eltTree.linkNodes('100','143')
eltTree.addNode('144','<b><i>&lt;choice&gt;</i></b>',null,true,false)
eltTree.linkNodes('143','144')
eltTree.linkNodes('144','116','<b>RangeFilter</b>')
eltTree.linkNodes('144','122','<b>CachedFilter</b>')
eltTree.linkNodes('96','104','<b>TermQuery</b>')
eltTree.linkNodes('96','107','<b>TermsQuery</b>')
eltTree.linkNodes('96','112','<b>MatchAllDocsQuery</b>')
eltTree.linkNodes('96','113','<b>ConstantScoreQuery</b>')
eltTree.linkNodes('96','124','<b>SpanOr</b>')
eltTree.linkNodes('96','126','<b>SpanNear</b>')
eltTree.linkNodes('96','130','<b>SpanOrTerms</b>')
eltTree.linkNodes('96','132','<b>SpanFirst</b>')
eltTree.linkNodes('96','136','<b>SpanNot</b>')
eltTree.linkNodes('96','139','<b>SpanTerm</b>')
eltTree.linkNodes('96','116','<b>RangeFilter</b>')
eltTree.linkNodes('96','122','<b>CachedFilter</b>')
eltTree.linkNodes('87','122','CachedFilter')
eltTree.linkNodes('87','94','Clause')
eltTree.linkNodes('87','113','ConstantScoreQuery')
eltTree.linkNodes('87','141','Exclude')
eltTree.linkNodes('87','143','Filter')
eltTree.linkNodes('87','100','FilteredQuery')
eltTree.linkNodes('87','137','Include')
eltTree.linkNodes('87','112','MatchAllDocsQuery')
eltTree.linkNodes('87','102','Query')
eltTree.linkNodes('87','116','RangeFilter')
eltTree.linkNodes('87','132','SpanFirst')
eltTree.linkNodes('87','126','SpanNear')
eltTree.linkNodes('87','136','SpanNot')
eltTree.linkNodes('87','124','SpanOr')
eltTree.linkNodes('87','130','SpanOrTerms')
eltTree.linkNodes('87','139','SpanTerm')
eltTree.linkNodes('87','104','TermQuery')
eltTree.linkNodes('87','107','TermsQuery')
eltTree.linkNodes('87','97','UserQuery')
document.write(eltTree);
//-->
</script>

View File

@ -40,6 +40,7 @@ public class UserInputQueryBuilder implements QueryBuilder {
private String defaultField;
/**
* This constructor has the disadvantage of not being able to change choice of default field name
* @param parser thread un-safe query parser
*/
public UserInputQueryBuilder(QueryParser parser) {
@ -68,8 +69,9 @@ public class UserInputQueryBuilder implements QueryBuilder {
}
else
{
String fieldName=DOMUtils.getAttribute(e, "fieldName", defaultField);
//Create new parser
QueryParser parser=new QueryParser(defaultField,analyzer);
QueryParser parser=createQueryParser(fieldName, analyzer);
q = parser.parse(text);
}
q.setBoost(DOMUtils.getAttribute(e,"boost",1.0f));
@ -78,5 +80,16 @@ public class UserInputQueryBuilder implements QueryBuilder {
throw new ParserException(e1.getMessage());
}
}
/**
* Method to create a QueryParser - designed to be overridden
* @param fieldName
* @param analyzer
* @return
*/
protected QueryParser createQueryParser(String fieldName, Analyzer analyzer)
{
return new QueryParser(fieldName,analyzer);
}
}

View File

@ -117,6 +117,14 @@ public class TestParser extends TestCase {
Query q=parse("UserInputQuery.xml");
dumpResults("UserInput with Filter", q, 5);
}
public void testCustomFieldUserQueryXML() throws ParserException, IOException
{
Query q=parse("UserInputQueryCustomField.xml");
Hits h = searcher.search(q);
assertEquals("UserInputQueryCustomField should produce 0 result ", 0,h.length());
}
public void testLikeThisQueryXML() throws Exception
{
Query q=parse("LikeThisQuery.xml");

View File

@ -0,0 +1,2 @@
<?xml version="1.0" encoding="UTF-8"?>
<UserQuery fieldName="doesNotExist">Bank</UserQuery>