Class CCEffectResponse
java.lang.Object
live.crowdcontrol.cc4j.websocket.data.CCEffectResponse
- Direct Known Subclasses:
CCInstantEffectResponse,CCTimedEffectResponse
Informs the server of whether a purchased effect was executed successfully or not.
- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCCEffectResponse(@NotNull UUID requestID, @NotNull ResponseStatus status, @NotNull String message) Creates a response. -
Method Summary
Modifier and TypeMethodDescription@NotNull UUIDgetId()Gets the randomly generated ID of the argument.@NotNull StringGets the message to be displayed to the viewer about the status.@NotNull UUIDGets the ID of the request that this result is in response to.@NotNull ResponseStatusThe status value of the result.intGets the timestamp in seconds since Unix epoch that this result was generated.
-
Field Details
-
id
-
stamp
protected final int stamp -
request
-
message
-
status
-
-
Constructor Details
-
CCEffectResponse
protected CCEffectResponse(@NotNull @NotNull UUID requestID, @NotNull @NotNull ResponseStatus status, @NotNull @NotNull String message) Creates a response.- Parameters:
requestID- the ID of the requeststatus- the status of the requestmessage- the reasoning to display to the viewer
-
-
Method Details
-
getId
Gets the randomly generated ID of the argument.- Returns:
- arg ID
-
getRequestId
Gets the ID of the request that this result is in response to.- Returns:
- request ID
-
getTimestamp
public int getTimestamp()Gets the timestamp in seconds since Unix epoch that this result was generated.- Returns:
- unix epoch seconds timestamp
-
getMessage
Gets the message to be displayed to the viewer about the status. May not be displayed if the status is successful. String may be empty if nothing is to be displayed.- Returns:
- message
-
getStatus
The status value of the result.- Returns:
- result status
-