Package com.redis.vl.schema
Class TextField.TextFieldBuilder
java.lang.Object
com.redis.vl.schema.TextField.TextFieldBuilder
- Enclosing class:
TextField
Fluent builder for TextField
-
Method Summary
Modifier and TypeMethodDescriptionSet the field aliasbuild()
Build the TextFieldindexed
(boolean indexed) Set whether the field is indexedSet the field namenoStem()
Disable stemming for this fieldnoStem
(boolean noStem) Set whether to disable stemmingSet the phonetic matchersortable()
Set the field as sortablesortable
(boolean sortable) Set whether the field is sortableweight
(double weight) Set the weight for scoring in full-text searchSet the field alias (alternative method)withPhonetic
(String phonetic) Set the phonetic matcher (alternative method)withWeight
(double weight) Set the weight for scoring in full-text search (alternative method)
-
Method Details
-
name
Set the field name- Parameters:
name
- Field name- Returns:
- This builder
-
alias
Set the field alias- Parameters:
alias
- Field alias- Returns:
- This builder
-
withAlias
Set the field alias (alternative method)- Parameters:
alias
- Field alias- Returns:
- This builder
-
indexed
Set whether the field is indexed- Parameters:
indexed
- True if indexed- Returns:
- This builder
-
sortable
Set whether the field is sortable- Parameters:
sortable
- True if sortable- Returns:
- This builder
-
sortable
Set the field as sortable- Returns:
- This builder
-
weight
Set the weight for scoring in full-text search- Parameters:
weight
- Weight value- Returns:
- This builder
-
withWeight
Set the weight for scoring in full-text search (alternative method)- Parameters:
weight
- Weight value- Returns:
- This builder
-
noStem
Set whether to disable stemming- Parameters:
noStem
- True to disable stemming- Returns:
- This builder
-
noStem
Disable stemming for this field- Returns:
- This builder
-
phonetic
Set the phonetic matcher- Parameters:
phonetic
- Phonetic matcher (e.g., "dm:en" for Double Metaphone English)- Returns:
- This builder
-
withPhonetic
Set the phonetic matcher (alternative method)- Parameters:
phonetic
- Phonetic matcher (e.g., "dm:en" for Double Metaphone English)- Returns:
- This builder
-
build
Build the TextField- Returns:
- TextField instance
-