The Term type exposes the following members.

Constructors

  NameDescription
Public methodTerm(String)
Constructs a Term with the given field and empty text. This serves two purposes: 1) reuse of a Term with the same field. 2) pattern for a query.
Public methodTerm(String, String)
Constructs a Term with the given field and text.

Note that a null field or null text value results in undefined behavior for most Lucene APIs that accept a Term parameter.

Methods

  NameDescription
Public methodCompareTo(Object)
Public methodCompareTo(Term)
Compares two terms, returning a negative integer if this term belongs before the argument, zero if this term is equal to the argument, and a positive integer if this term belongs after the argument. The ordering of terms is first by field, then by text.
Public methodCreateTerm
Optimized construction of new Terms by reusing same field as this Term - avoids field.intern() overhead
Public methodEquals (Overrides Object..::..Equals(Object).)
Public methodField
Returns the field of this term, an interned string. The field indicates the part of a document which this term came from.
Protected methodFinalize
Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection.
(Inherited from Object.)
Public methodGetHashCode (Overrides Object..::..GetHashCode()()()().)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodText
Returns the text of this term. In the case of words, this is simply the text of the word. In the case of dates and other types, this is an encoding of the object as a string.
Public methodToString (Overrides Object..::..ToString()()()().)

Properties

  NameDescription
Public propertytext_ForNUnit

See Also