Class StringField
A field that is indexed but not tokenized: the entire System.String value is indexed as a single token. For example this might be used for a 'country' field or an 'id' field, or any field that you intend to use for sorting or access through the field cache.
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
Namespace: Lucene.Net.Documents
Assembly: Lucene.Net.dll
Syntax
public sealed class StringField : Field, IIndexableField, IFormattable
Constructors
| Improve this Doc View SourceStringField(String, String, Field.Store)
Creates a new StringField (a field that is indexed but not tokenized)
Declaration
public StringField(string name, string value, Field.Store stored)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | field name |
System.String | value | System.String value |
Field.Store | stored | YES if the content should also be stored |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | if the field |
Fields
| Improve this Doc View SourceTYPE_NOT_STORED
Indexed, not tokenized, omits norms, indexes DOCS_ONLY, not stored.
Declaration
public static readonly FieldType TYPE_NOT_STORED
Field Value
Type | Description |
---|---|
FieldType |
TYPE_STORED
Indexed, not tokenized, omits norms, indexes DOCS_ONLY, stored
Declaration
public static readonly FieldType TYPE_STORED
Field Value
Type | Description |
---|---|
FieldType |
Implements
System.IFormattable