Fork me on GitHub
  • API

    Show / Hide Table of Contents

    Class AbstractRangeQueryNode<T>

    This class should be extended by nodes intending to represent range queries.

    Inheritance
    object
    QueryNode
    AbstractRangeQueryNode<T>
    NumericRangeQueryNode
    TermRangeQueryNode
    Implements
    IAbstractRangeQueryNode
    IRangeQueryNode<IFieldableNode>
    IRangeQueryNode
    IFieldableNode
    IQueryNode
    Inherited Members
    QueryNode.PLAINTEXT_FIELD_NAME
    QueryNode.Allocate()
    QueryNode.Add(IQueryNode)
    QueryNode.Add(IList<IQueryNode>)
    QueryNode.IsLeaf
    QueryNode.Set(IList<IQueryNode>)
    QueryNode.CloneTree()
    QueryNode.Clone()
    QueryNode.GetChildren()
    QueryNode.SetTag(string, object)
    QueryNode.UnsetTag(string)
    QueryNode.ContainsTag(string)
    QueryNode.GetTag(string)
    QueryNode.TryGetTag(string, out object)
    QueryNode.Parent
    QueryNode.IsRoot
    QueryNode.m_toQueryStringIgnoreFields
    QueryNode.IsDefaultField(string)
    QueryNode.TagMap
    QueryNode.RemoveChildren(IQueryNode)
    QueryNode.RemoveFromParent()
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    Namespace: Lucene.Net.QueryParsers.Flexible.Standard.Nodes
    Assembly: Lucene.Net.QueryParser.dll
    Syntax
    public class AbstractRangeQueryNode<T> : QueryNode, IAbstractRangeQueryNode, IRangeQueryNode<IFieldableNode>, IRangeQueryNode, IFieldableNode, IQueryNode where T : IFieldableNode
    Type Parameters
    Name Description
    T

    the type of the range query bounds (lower and upper)

    Constructors

    AbstractRangeQueryNode()

    Constructs an AbstractRangeQueryNode<T>, it should be invoked only by its extenders.

    Declaration
    protected AbstractRangeQueryNode()

    Properties

    Field

    Gets or Sets the field associated with this node.

    Declaration
    public virtual string Field { get; set; }
    Property Value
    Type Description
    string
    See Also
    IFieldableNode

    IsLowerInclusive

    Gets whether the lower bound is inclusive or exclusive.

    Declaration
    public virtual bool IsLowerInclusive { get; }
    Property Value
    Type Description
    bool
    Remarks

    true if the lower bound is inclusive, otherwise, false

    IsUpperInclusive

    Gets whether the upper bound is inclusive or exclusive.

    Declaration
    public virtual bool IsUpperInclusive { get; }
    Property Value
    Type Description
    bool
    Remarks

    true if the upper bound is inclusive, otherwise, false

    LowerBound

    Gets the lower bound node.

    Declaration
    public virtual IFieldableNode LowerBound { get; }
    Property Value
    Type Description
    IFieldableNode

    UpperBound

    Gets the upper bound node.

    Declaration
    public virtual IFieldableNode UpperBound { get; }
    Property Value
    Type Description
    IFieldableNode

    Methods

    SetBounds(T, T, bool, bool)

    Sets the lower and upper bounds.

    Declaration
    public virtual void SetBounds(T lower, T upper, bool lowerInclusive, bool upperInclusive)
    Parameters
    Type Name Description
    T lower

    the lower bound, null if lower bound is open

    T upper

    the upper bound, null if upper bound is open

    bool lowerInclusive

    true if the lower bound is inclusive, otherwise, false

    bool upperInclusive

    true if the upper bound is inclusive, otherwise, false

    See Also
    LowerBound
    UpperBound
    IsLowerInclusive
    IsUpperInclusive

    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
    QueryNode.ToQueryString(IEscapeQuerySyntax)

    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
    Overrides
    QueryNode.ToString()
    See Also
    ToString()

    Implements

    IAbstractRangeQueryNode
    IRangeQueryNode<T>
    IRangeQueryNode
    IFieldableNode
    IQueryNode
    Back to top Copyright © 2024 The Apache Software Foundation, Licensed under the Apache License, Version 2.0
    Apache Lucene.Net, Lucene.Net, Apache, the Apache feather logo, and the Apache Lucene.Net project logo are trademarks of The Apache Software Foundation.
    All other marks mentioned may be trademarks or registered trademarks of their respective owners.