Package glide.api.models.commands
Class HSetExOptions.HSetExOptionsBuilder
- java.lang.Object
-
- glide.api.models.commands.HSetExOptions.HSetExOptionsBuilder
-
- Enclosing class:
- HSetExOptions
public static class HSetExOptions.HSetExOptionsBuilder extends java.lang.ObjectBuilder class forHSetExOptions.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description HSetExOptionsbuild()HSetExOptions.HSetExOptionsBuilderexpiry(ExpirySet expiry)Expiry configuration for the hash fields.HSetExOptions.HSetExOptionsBuilderfieldConditionalChange(FieldConditionalChange fieldConditionalChange)Field conditional change option (FNX/FXX) for controlling when fields are set.HSetExOptions.HSetExOptionsBuilderonlyIfAllExist()Sets the field conditional change to only set fields if all of them already exist.HSetExOptions.HSetExOptionsBuilderonlyIfNoneExist()Sets the field conditional change to only set fields if none of them already exist.java.lang.StringtoString()
-
-
-
Method Detail
-
onlyIfAllExist
public HSetExOptions.HSetExOptionsBuilder onlyIfAllExist()
Sets the field conditional change to only set fields if all of them already exist.This is equivalent to the FXX option in the Valkey HSETEX command. When this option is used, the command will only update existing fields and will not create new fields.
- Returns:
- this builder instance for method chaining
- See Also:
FieldConditionalChange.ONLY_IF_ALL_EXIST
-
onlyIfNoneExist
public HSetExOptions.HSetExOptionsBuilder onlyIfNoneExist()
Sets the field conditional change to only set fields if none of them already exist.This is equivalent to the FNX option in the Valkey HSETEX command. When this option is used, the command will only create new fields and will not update existing fields.
- Returns:
- this builder instance for method chaining
- See Also:
FieldConditionalChange.ONLY_IF_NONE_EXIST
-
fieldConditionalChange
public HSetExOptions.HSetExOptionsBuilder fieldConditionalChange(FieldConditionalChange fieldConditionalChange)
Field conditional change option (FNX/FXX) for controlling when fields are set.- Returns:
this.
-
expiry
public HSetExOptions.HSetExOptionsBuilder expiry(ExpirySet expiry)
Expiry configuration for the hash fields.- Returns:
this.
-
build
public HSetExOptions build()
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-