Class RegexpQueryNode
A RegexpQueryNode represents Lucene.Net.Search.RegexpQuery query Examples: /[a-z]|[0-9]/
Inherited Members
Namespace: Lucene.Net.QueryParsers.Flexible.Standard.Nodes
Assembly: Lucene.Net.QueryParser.dll
Syntax
public class RegexpQueryNode : QueryNode, ITextableQueryNode, IFieldableNode, IQueryNode
Constructors
RegexpQueryNode(string, ICharSequence, int, int)
A RegexpQueryNode represents Lucene.Net.Search.RegexpQuery query Examples: /[a-z]|[0-9]/
Declaration
public RegexpQueryNode(string field, ICharSequence text, int begin, int end)
Parameters
Type | Name | Description |
---|---|---|
string | field | field name |
ICharSequence | text | value that contains a regular expression |
int | begin | position in the query string |
int | end | position in the query string |
RegexpQueryNode(string, string, int, int)
A RegexpQueryNode represents Lucene.Net.Search.RegexpQuery query Examples: /[a-z]|[0-9]/
Declaration
public RegexpQueryNode(string field, string text, int begin, int end)
Parameters
Type | Name | Description |
---|---|---|
string | field | field name |
string | text | value that contains a regular expression |
int | begin | position in the query string |
int | end | position in the query string |
RegexpQueryNode(string, StringBuilder, int, int)
A RegexpQueryNode represents Lucene.Net.Search.RegexpQuery query Examples: /[a-z]|[0-9]/
Declaration
public RegexpQueryNode(string field, StringBuilder text, int begin, int end)
Parameters
Type | Name | Description |
---|---|---|
string | field | field name |
StringBuilder | text | value that contains a regular expression |
int | begin | position in the query string |
int | end | position in the query string |
Properties
Field
Gets or Sets the field name associated to the node and every node under it.
Declaration
public virtual string Field { get; set; }
Property Value
Type | Description |
---|---|
string |
Text
A RegexpQueryNode represents Lucene.Net.Search.RegexpQuery query Examples: /[a-z]|[0-9]/
Declaration
public virtual ICharSequence Text { get; set; }
Property Value
Type | Description |
---|---|
ICharSequence |
Methods
CloneTree()
Recursive clone the IQueryNode tree. The tags are not copied to the new tree when you call the CloneTree() method.
Declaration
public override IQueryNode CloneTree()
Returns
Type | Description |
---|---|
IQueryNode | the cloned tree |
Overrides
GetFieldAsString()
A RegexpQueryNode represents Lucene.Net.Search.RegexpQuery query Examples: /[a-z]|[0-9]/
Declaration
public virtual string GetFieldAsString()
Returns
Type | Description |
---|---|
string |
TextToBytesRef()
A RegexpQueryNode represents Lucene.Net.Search.RegexpQuery query Examples: /[a-z]|[0-9]/
Declaration
public virtual BytesRef TextToBytesRef()
Returns
Type | Description |
---|---|
BytesRef |
ToQueryString(IEscapeQuerySyntax)
convert to a query string understood by the query parser
Declaration
public override string ToQueryString(IEscapeQuerySyntax escapeSyntaxParser)
Parameters
Type | Name | Description |
---|---|---|
IEscapeQuerySyntax | escapeSyntaxParser |
Returns
Type | Description |
---|---|
string |
Overrides
ToString()
Every implementation of this class should return pseudo xml like this:
For FieldQueryNode: <field start='1' end='2' field='subject' text='foo'/>
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
string |