Class ReactiveAutoSuggestCommandsImpl<K>
java.lang.Object
io.quarkus.redis.runtime.datasource.AbstractRedisCommands
io.quarkus.redis.runtime.datasource.AbstractAutoSuggestCommands<K>
io.quarkus.redis.runtime.datasource.ReactiveAutoSuggestCommandsImpl<K>
- All Implemented Interfaces:
ReactiveAutoSuggestCommands<K>
,ReactiveRedisCommands
public class ReactiveAutoSuggestCommandsImpl<K>
extends AbstractAutoSuggestCommands<K>
implements ReactiveAutoSuggestCommands<K>, ReactiveRedisCommands
-
Field Summary
Fields inherited from class io.quarkus.redis.runtime.datasource.AbstractRedisCommands
marshaller, redis
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) List<Suggestion>
decodeAsListOfSuggestion
(io.vertx.mutiny.redis.client.Response response, boolean hasScores) io.smallrye.mutiny.Uni<Long>
Execute the command FT.SUGADD.io.smallrye.mutiny.Uni<Boolean>
Execute the command FT.SUGDEL.io.smallrye.mutiny.Uni<List<Suggestion>>
Execute the command FT.SUGGET.io.smallrye.mutiny.Uni<List<Suggestion>>
Execute the command FT.SUGGET.io.smallrye.mutiny.Uni<Long>
Execute the command FT.SUGLEN.Methods inherited from class io.quarkus.redis.runtime.datasource.AbstractAutoSuggestCommands
_ftSugAdd, _ftSugDel, _ftSugget, _ftSugget, _ftSugLen
Methods inherited from class io.quarkus.redis.runtime.datasource.AbstractRedisCommands
execute, isMap
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.quarkus.redis.datasource.autosuggest.ReactiveAutoSuggestCommands
ftSugAdd
-
Constructor Details
-
ReactiveAutoSuggestCommandsImpl
-
-
Method Details
-
getDataSource
- Specified by:
getDataSource
in interfaceReactiveRedisCommands
- Returns:
- the data source.
-
ftSugAdd
Description copied from interface:ReactiveAutoSuggestCommands
Execute the command FT.SUGADD. Summary: Add a suggestion string to an auto-complete suggestion dictionary Group: auto-suggest- Specified by:
ftSugAdd
in interfaceReactiveAutoSuggestCommands<K>
- Parameters:
key
- the suggestion dictionary keystring
- the suggestion string to indexscore
- the floating point number of the suggestion string's weightincrement
- increments the existing entry of the suggestion by the given score, instead of replacing the score. This is useful for updating the dictionary based on user queries in real time.- Returns:
- A uni emitting the current size of the suggestion dictionary.
-
ftSugDel
Description copied from interface:ReactiveAutoSuggestCommands
Execute the command FT.SUGDEL. Summary: Delete a string from a suggestion index Group: auto-suggest- Specified by:
ftSugDel
in interfaceReactiveAutoSuggestCommands<K>
- Parameters:
key
- the suggestion dictionary keystring
- the suggestion string to index- Returns:
- A uni emitting
true
if the value was found,false
otherwise
-
ftSugGet
Description copied from interface:ReactiveAutoSuggestCommands
Execute the command FT.SUGGET. Summary: Get completion suggestions for a prefix Group: auto-suggest- Specified by:
ftSugGet
in interfaceReactiveAutoSuggestCommands<K>
- Parameters:
key
- the suggestion dictionary keyprefix
- is prefix to complete on.- Returns:
- A uni emitting a list of the top suggestions matching the prefix, optionally with score after each entry.
-
ftSugGet
Description copied from interface:ReactiveAutoSuggestCommands
Execute the command FT.SUGGET. Summary: Get completion suggestions for a prefix Group: auto-suggest- Specified by:
ftSugGet
in interfaceReactiveAutoSuggestCommands<K>
- Parameters:
key
- the suggestion dictionary keyprefix
- is prefix to complete on.args
- the extra argument, must not benull
- Returns:
- A uni emitting
true
if the value was found,false
otherwise
-
decodeAsListOfSuggestion
List<Suggestion> decodeAsListOfSuggestion(io.vertx.mutiny.redis.client.Response response, boolean hasScores) -
ftSugLen
Description copied from interface:ReactiveAutoSuggestCommands
Execute the command FT.SUGLEN. Summary: Get the size of an auto-complete suggestion dictionary Group: auto-suggest- Specified by:
ftSugLen
in interfaceReactiveAutoSuggestCommands<K>
- Parameters:
key
- the suggestion dictionary key- Returns:
- A uni emitting the current size of the suggestion dictionary.
-