Section navigation

Public classSealed StringField

Namespace
Rowles.LeanCorpus.Document.Fields
Assembly
Rowles.LeanCorpus.dll

Exact-match field stored as-is, not passed through the analyser.

public sealed class StringField : IField
Inheritance
StringField
Implements

Public constructor StringField(string, string)

Initialises a new StringField with the specified name and value.

Public constructor StringField(string, string, bool)

Initialises a new StringField with the specified name, value, and stored-field behaviour.

Public constructor StringField(string, string, bool, float, StringDocValues, FieldIndexOptions)

Initialises a string field with explicit DocValues representations.

Public constructor StringField(string, string, bool, float, bool, FieldIndexOptions)

Initialises a new StringField with the specified name, value, stored-field behaviour, and index-time boost.

Public property Boost

Index-time boost applied to queries that score this field.

Public property DocValues

Gets the explicitly selected DocValues representations.

Public property FieldType

The kind of data this field holds.

Public property IndexOptions

Controls which postings data (doc IDs, frequencies, positions, offsets) is written to the inverted index. Lower levels reduce disk usage and indexing time but disable phrase queries and scoring features. Default: DocsAndFreqsAndPositions for TextField; DocsAndFreqs for StringField; DocsOnly for NumericField.

Public property IsIndexed

Whether the field is included in the inverted index.

Public property IsStored

Whether the raw value is persisted in stored fields.

Public property Name

Field name used for indexing and retrieval.

Public property StoreDocValues

Whether to populate DocValues (sorted, sorted-set, numeric, binary) for this field. When false, no DocValues sidecar files are produced for the field. Default: true for StringField and NumericField; false for TextField, StoredField, and BinaryField.

Public property Value

Gets the exact string value of this field.