public class SetNameCommand extends Command<SetNameCommand>
Command.Tags
Constructor and Description |
---|
SetNameCommand(@NonNull Client client)
Constructs the command.
|
Modifier and Type | Method and Description |
---|---|
void |
execute()
Executes the command.
|
@NonNull SetNameCommand |
newName(@Nullable String newName)
Sets the new name.
|
protected @NonNull ToStringer |
toStringer()
Generates a partial
ToStringer for the command. |
getClient, sendCommandLine, sendCommandLine, tags, toString
public SetNameCommand(@NonNull Client client)
client
- the clientIllegalArgumentException
- if client is nullpublic @NonNull SetNameCommand newName(@Nullable String newName)
newName
- new nameIllegalArgumentException
- for invalid messagepublic void execute()
Command
execute
in class Command<SetNameCommand>
protected @NonNull ToStringer toStringer()
Command
ToStringer
for the command.toStringer
in class Command<SetNameCommand>
Copyright © 2013–2021 Kitteh. All rights reserved.