RangeQuery localNames = new RangeQuery(getLowerLocalNameTerm(), getUpperLocalNameTerm(), inclusive);
BooleanQuery query = new BooleanQuery();
query.add(new JcrTermQuery(new Term(FieldNames.NAMESPACE_URI, getNamespaceURI())),
BooleanClause.Occur.MUST);
query.add(localNames, BooleanClause.Occur.MUST);
return query.rewrite(reader);
}
else
{
return new RangeQuery(getLowerTerm(), getUpperTerm(), inclusive).rewrite(reader);
}