package com.ym.mec.common.entity;

/**
 * HttpResponse 返回结果
 */
public class HttpResponseResult {

	public final static int TIME_OUT = -1;

	private boolean status = true;
	private String msg;
	private Object data;
	private int code;

	public HttpResponseResult(boolean status, int code, Object data, String message) {
		this.status = status;
		this.msg = message;
		this.data = data;
		this.code = code;
	}

	public HttpResponseResult() {
	}

	public int getCode() {
		return code;
	}

	public void setCode(int code) {
		this.code = code;
	}

	public boolean getStatus() {
		return status;
	}

	public void setStatus(boolean status) {
		this.status = status;
	}

	public String getMsg() {
		return msg;
	}

	public void setMsg(String msg) {
		this.msg = msg;
	}

	public Object getData() {
		return data;
	}

	public void setData(Object data) {
		this.data = data;
	}

	public void success() {
		this.status = true;
	}

	public void fail() {
		this.status = false;
	}

}
