package com.changhong.autoform.entity.system;
|
|
public class RestResult<T> {
|
/**
|
* 应答/错误代码
|
*/
|
private String rspCode;
|
|
/**
|
* 应答/错误描述
|
*/
|
private String rspDesc;
|
|
/**
|
* 返回结果数据
|
*/
|
private T data;
|
|
private RestResult() {}
|
|
public static <T> RestResult<T> newInstance() {
|
return new RestResult<>();
|
}
|
|
public String getRspCode() {
|
return rspCode;
|
}
|
|
public void setRspCode(String rspCode) {
|
this.rspCode = rspCode;
|
}
|
|
public String getRspDesc() {
|
return rspDesc;
|
}
|
|
public void setRspDesc(String rspDesc) {
|
this.rspDesc = rspDesc;
|
}
|
|
public T getData() {
|
return data;
|
}
|
|
public void setData(T data) {
|
this.data = data;
|
}
|
|
@Override
|
public String toString() {
|
return "RestResult{" +
|
"rspCode=" + rspCode +
|
", message='" + rspDesc + '\'' +
|
", data=" + data +
|
'}';
|
}
|
}
|