Class RegexpQuery
A fast regular expression query based on the Lucene.Net.Util.Automaton package.
- Comparisons are fast
- The term dictionary is enumerated in an intelligent way, to avoid comparisons. See AutomatonQuery for more details.
The supported syntax is documented in the RegExp class. Note this might be different than other regular expression implementations. For some alternatives with different syntax, look under the sandbox.
Note this query can be slow, as it needs to iterate over many terms. In order
to prevent extremely slow RegexpQuerys, a RegExp term should not start with
the expression .*
Inherited Members
Assembly: DistributedLucene.Net.dll
Syntax
public class RegexpQuery : AutomatonQuery
Constructors
Name | Description |
---|---|
RegexpQuery(Term) | Constructs a query for terms matching By default, all regular expression features are enabled. |
RegexpQuery(Term, RegExpSyntax) | Constructs a query for terms matching |
RegexpQuery(Term, RegExpSyntax, IAutomatonProvider) | Constructs a query for terms matching |
Methods
Name | Description |
---|---|
ToString(String) | Prints a user-readable version of this query. |