java.lang.Object
io.lettuce.core.KillArgs
- All Implemented Interfaces:
CompositeArgument
public class KillArgs extends Object implements CompositeArgument
Argument list builder for the Redis CLIENT KILL command. Static import the
methods from
KillArgs.Builder and chain the method calls: id(1).skipme().
KillArgs is a mutable object and instances should be used only once to avoid shared mutable state.
- Since:
- 3.0
- Author:
- Mark Paluch, dengliming
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classKillArgs.BuilderBuilder entry points forKillArgs. -
Constructor Summary
Constructors Constructor Description KillArgs() -
Method Summary
Modifier and Type Method Description KillArgsaddr(String addr)Kill the client ataddr(Remote Address).<K, V> voidbuild(CommandArgs<K,V> args)Build command arguments and contribute arguments toCommandArgs.KillArgsid(long id)Kill the client with its clientid.KillArgsladdr(String laddr)Kill the client atladdr(Local Address).KillArgsskipme()By default this option is enabled, that is, the client calling the command will not get killed, however setting this option to no will have the effect of also killing the client calling the command.KillArgsskipme(boolean state)By default this option is enabled, that is, the client calling the command will not get killed, however setting this option to no will have the effect of also killing the client calling the command.KillArgstype(io.lettuce.core.KillArgs.Type type)This closes the connections of all the clients in the specifiedKillArgs.Type.KillArgsuser(String username)Closes all the connections that are authenticated with the specified ACLusername.
-
Constructor Details
-
KillArgs
public KillArgs()
-
-
Method Details
-
skipme
By default this option is enabled, that is, the client calling the command will not get killed, however setting this option to no will have the effect of also killing the client calling the command.- Returns:
thisMigrateArgs.
-
skipme
By default this option is enabled, that is, the client calling the command will not get killed, however setting this option to no will have the effect of also killing the client calling the command.- Parameters:
state-- Returns:
thisKillArgs.
-
addr
Kill the client ataddr(Remote Address).- Parameters:
addr- must not benull.- Returns:
thisKillArgs.
-
laddr
Kill the client atladdr(Local Address).- Parameters:
laddr- must not benull.- Returns:
thisKillArgs.- Since:
- 6.1
-
id
Kill the client with its clientid.- Parameters:
id-- Returns:
thisKillArgs.
-
type
This closes the connections of all the clients in the specifiedKillArgs.Type. Note that clients blocked into the MONITOR command are considered to belong to the normal class.- Parameters:
type- must not benull.- Returns:
thisKillArgs.
-
user
Closes all the connections that are authenticated with the specified ACLusername.- Parameters:
username- must not benull.- Returns:
thisKillArgs.- Since:
- 6.1
-
build
Description copied from interface:CompositeArgumentBuild command arguments and contribute arguments toCommandArgs.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.
- Specified by:
buildin interfaceCompositeArgument- Type Parameters:
K- Key type.V- Value type.- Parameters:
args- the command arguments, must not benull.
-