com.apitrary.api.response.Response Maven / Gradle / Ivy
/*
* Copyright 2012-2013 Denis Neuling
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.apitrary.api.response;
import java.io.Serializable;
/**
*
* Abstract Response class.
*
*
* @author Denis Neuling ([email protected])
*
*/
public abstract class Response implements Serializable {
private static final long serialVersionUID = 5050233742143155805L;
protected String result;
protected String statusMessage;
protected int statusCode;
protected long responseTime;
/**
*
* Getter for the field result
.
*
*
* @return a {@link java.lang.String} object.
*/
public String getResult() {
return result;
}
/**
*
* Setter for the field result
.
*
*
* @param result
* a {@link java.lang.String} object.
*/
public void setResult(String result) {
this.result = result;
}
/**
*
* Getter for the field statusMessage
.
*
*
* @return a {@link java.lang.String} object.
*/
public String getStatusMessage() {
return statusMessage;
}
/**
*
* Setter for the field statusMessage
.
*
*
* @param statusMessage
* a {@link java.lang.String} object.
*/
public void setStatusMessage(String statusMessage) {
this.statusMessage = statusMessage;
}
/**
*
* Getter for the field statusCode
.
*
*
* @return a int.
*/
public int getStatusCode() {
return statusCode;
}
/**
*
* Setter for the field statusCode
.
*
*
* @param statusCode
* a int.
*/
public void setStatusCode(int statusCode) {
this.statusCode = statusCode;
}
/**
*
* Getter for the field responseTime
.
*
*
* @return a long.
*/
public long getResponseTime() {
return responseTime;
}
/**
*
* Setter for the field responseTime
.
*
*
* @param responseTime
* a long.
*/
public void setResponseTime(long responseTime) {
this.responseTime = responseTime;
}
/** {@inheritDoc} */
@Override
public String toString() {
return "Response [result=" + result + ", statusMessage=" + statusMessage + ", statusCode=" + statusCode + ", responseTime=" + responseTime + "]";
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy