public class CommandResult
extends java.lang.Object
| Constructor and Description |
|---|
CommandResult(boolean success,
@NotNull MessageTarget sender) |
| Modifier and Type | Method and Description |
|---|---|
void |
assertFailed()
Asserts if the returned code of the executed command is not
false. |
void |
assertNoResponse()
Asserts if more messages have been sent to the command sender.
|
void |
assertResponse(java.lang.String message)
Assets if the given message was not the next message send to the command sender.
|
void |
assertResponse(java.lang.String format,
java.lang.Object... objects)
Asserts if a given formatted message was not the next message sent to the command sender.
|
void |
assertSucceeded()
Asserts if the returned code of the executed command is not
true. |
boolean |
hasSucceeded()
Check if the command executed successfully.
|
public CommandResult(boolean success,
@NotNull
@NotNull MessageTarget sender)
public boolean hasSucceeded()
true if the command executed successfully, false if a problem occured.public void assertSucceeded()
true.public void assertFailed()
false.public void assertResponse(java.lang.String message)
message - The message to check for.public void assertResponse(java.lang.String format,
java.lang.Object... objects)
format - The formatted message to check for.objects - The objects to place into the formatted message.public void assertNoResponse()