Package com.redis.vl.schema
Class GeoField.GeoFieldBuilder
java.lang.Object
com.redis.vl.schema.GeoField.GeoFieldBuilder
- Enclosing class:
GeoField
Fluent builder for GeoField
-
Method Summary
Modifier and TypeMethodDescriptionSet the field alias.build()Build the GeoField.indexed(boolean indexed) Set whether the field is indexed.Index missing values (equivalent to indexMissing(true)).indexMissing(boolean indexMissing) Set whether to index missing values (documents without this field).Set the field name.sortable()Make the field sortable.sortable(boolean sortable) Set whether the field is sortable.Set the field alias (alternative method name).
-
Method Details
-
name
Set the field name.- Parameters:
name- The name for this field- Returns:
- This builder for chaining
-
alias
Set the field alias.- Parameters:
alias- The alias for this field- Returns:
- This builder for chaining
-
withAlias
Set the field alias (alternative method name).- Parameters:
alias- The alias for this field- Returns:
- This builder for chaining
-
indexed
Set whether the field is indexed.- Parameters:
indexed- True if the field should be indexed- Returns:
- This builder for chaining
-
sortable
Set whether the field is sortable.- Parameters:
sortable- True if the field should be sortable- Returns:
- This builder for chaining
-
sortable
Make the field sortable.- Returns:
- This builder for chaining
-
indexMissing
Set whether to index missing values (documents without this field).When enabled, allows searching for documents where this field is missing using the ismissing() filter.
- Parameters:
indexMissing- True to index missing values- Returns:
- This builder for chaining
-
indexMissing
Index missing values (equivalent to indexMissing(true)).When enabled, allows searching for documents where this field is missing using the ismissing() filter.
- Returns:
- This builder for chaining
-
build
Build the GeoField.- Returns:
- A new GeoField instance
- Throws:
IllegalArgumentException- if the field name is null or empty
-