FieldNumbers

class FieldNumbers(softDeletesFieldName: String?, parentFieldName: String?)

Constructors

Link copied to clipboard
constructor(softDeletesFieldName: String?, parentFieldName: String?)

Properties

Link copied to clipboard

Functions

Link copied to clipboard

Returns the global field number for the given field name. If the name does not exist yet, it tries to add it with the given preferred field number assigned, if possible, otherwise the first unassigned field number is used as the field number.

Link copied to clipboard
fun clear()
Link copied to clipboard
fun constructFieldInfo(fieldName: String, dvType: DocValuesType, newFieldNumber: Int): FieldInfo?

Construct a new FieldInfo based on the options in global field numbers. This method is not synchronized as all the options it uses are not modifiable.

Link copied to clipboard
Link copied to clipboard
fun verifyOrCreateDvOnlyField(fieldName: String, dvType: DocValuesType, fieldMustExist: Boolean)

This function is called from IndexWriter to verify if doc values of the field can be updated. If the field with this name already exists, we verify that it is a doc values-only field. If the field doesn't exist and the parameter fieldMustExist is false, we create a new field in the global field numbers.