public class Response
extends java.lang.Object
Constructor and Description |
---|
Response()
Response: Constructor without parameters
|
Response(Constants.CONNECTION_ERROR code)
Response: Constructor with error code
|
Response(Constants.CONNECTION_ERROR code,
java.lang.String msg)
Response: Constructor with message and error code
|
Response(java.lang.String msg)
Response: Constructor with message
|
Modifier and Type | Method and Description |
---|---|
Constants.CONNECTION_ERROR |
getErrorCode()
getErrorCode: return the error code received in the response.
|
java.lang.String |
getMessage()
getMessage: return the message from the response
|
void |
setErrorCode(Constants.CONNECTION_ERROR errorCode)
setErrorCode: set the initial error code.
|
void |
setMessage(java.lang.String message)
setMessage: set the message into the response
|
java.lang.String |
toString()
toString:
|
public Response()
public Response(Constants.CONNECTION_ERROR code, java.lang.String msg)
code:
- code of the error to setmsg:
- message to set in the responsepublic Response(java.lang.String msg)
msg:
- message to set in the responsepublic Response(Constants.CONNECTION_ERROR code)
code:
- code of the error to setpublic Constants.CONNECTION_ERROR getErrorCode()
public void setErrorCode(Constants.CONNECTION_ERROR errorCode)
errorCode
- the errorCode to setpublic java.lang.String getMessage()
public void setMessage(java.lang.String message)
message
- the message to setpublic java.lang.String toString()
toString
in class java.lang.Object