public class HGetExArgs extends Object implements CompositeArgument
HGetExArgs.Builder and chain the method calls: ex(10).nx().
HGetExArgs is a mutable object and instances should be used only once to avoid shared mutable state.
| Modifier and Type | Class and Description |
|---|---|
static class |
HGetExArgs.Builder
Builder entry points for
HGetExArgs. |
| Constructor and Description |
|---|
HGetExArgs() |
| Modifier and Type | Method and Description |
|---|---|
<K,V> void |
build(CommandArgs<K,V> args)
Build command arguments and contribute arguments to
CommandArgs. |
HGetExArgs |
ex(Duration timeout)
Set the specified expire time, in seconds.
|
HGetExArgs |
exAt(Instant timestamp)
Set the specified expire at time using a posix
timestamp. |
HGetExArgs |
persist()
Remove the time to live associated with the key.
|
HGetExArgs |
px(Duration timeout)
Set the specified expire time, in milliseconds.
|
HGetExArgs |
pxAt(Instant timestamp)
Set the specified expire at time using a posix
timestamp. |
public HGetExArgs ex(Duration timeout)
timeout - expire time in seconds.this HGetExArgs.public HGetExArgs exAt(Instant timestamp)
timestamp.timestamp - the timestamp type: posix time in seconds.this HGetExArgs.public HGetExArgs px(Duration timeout)
timeout - expire time in milliseconds.this HGetExArgs.public HGetExArgs pxAt(Instant timestamp)
timestamp.timestamp - the timestamp type: posix time in milliseconds.this HGetExArgs.public HGetExArgs persist()
this HGetExArgs.public <K,V> void build(CommandArgs<K,V> args)
CompositeArgumentCommandArgs.
Implementing classes are required to implement this method. Depending on the command nature and configured arguments, this method may contribute arguments but is not required to add arguments if none are specified.
build in interface CompositeArgumentK - Key type.V - Value type.args - the command arguments, must not be null.Copyright © 2025 lettuce.io. All rights reserved.