Package us.ajg0702.queue.api.spigot
Class MessagedResponse<T>
- java.lang.Object
-
- us.ajg0702.queue.api.spigot.MessagedResponse<T>
-
public class MessagedResponse<T> extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description MessagedResponse(T response, java.lang.String none)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getEither()
Gets either the response (as a string) or the none message, whichever is availablejava.lang.String
getNone()
Gets the "none" messageT
getResponse()
Gets the response from the method.
-
-
-
Constructor Detail
-
MessagedResponse
public MessagedResponse(T response, java.lang.String none)
-
-
Method Detail
-
getResponse
public T getResponse()
Gets the response from the method.- Returns:
- The response. Null if there is a "none" message
-
getNone
public java.lang.String getNone()
Gets the "none" message- Returns:
- The none message. null if there is a response.
-
getEither
public java.lang.String getEither()
Gets either the response (as a string) or the none message, whichever is available- Returns:
- A string
-
-