package com.eshore.pdip.mobile.phone.vo;
import java.io.Serializable;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import com.eshore.pdip.mobile.util.Pager;
import com.eshore.pdip.mobile.util.ResultCodes;
public class Result implements Serializable {
/* *
*
*/
private static final long serialVersionUID = 1L;
/* *
* ������
*/
private String resultCode = ResultCodes.INVOKE_SUCC;
private String msg;
private Object resultObj;
private List<?> resultList;
private String callback;
private int pageNo = 1; // ҳ��
private int pageSize = 10; // ÿҳ����
private int totalPageCount = 0; // ��ҳ��
private int totalCount = 0; // ������
private int currentPageNo = 1; // ������
public int getCurrentPageNo() {
return currentPageNo;
}
public void setCurrentPageNo( int currentPageNo) {
this.currentPageNo = currentPageNo;
}
private Map<String, Object> ignoreMap = new HashMap<String, Object>();
public String getMsg() {
return msg;
}
public void setMsg(String msg) {
this.msg = msg;
}
public Object getResultObj() {
return resultObj;
}
public void setResultObj(Object resultObj) {
this.resultObj = resultObj;
}
public List<?> getResultList() {
return resultList;
}
public void setResultList(List<?> resultList) {
this.resultList = resultList;
}
public int getPageNo() {
return pageNo;
}
public void setPageNo( int pageNo) {
this.pageNo = pageNo;
}
public int getPageSize() {
return pageSize;
}
public void setPageSize( int pageSize) {
this.pageSize = pageSize;
}
public int getTotalPageCount() {
return totalPageCount;
}
public void setTotalPageCount( int totalPageCount) {
this.totalPageCount = totalPageCount;
}
public int getTotalCount() {
return totalCount;
}
public void setTotalCount( int totalCount) {
this.totalCount = totalCount;
}
public Map<String, Object> getIgnoreMap() {
return ignoreMap;
}
public void setIgnoreMap(Map<String, Object> ignoreMap) {
this.ignoreMap = ignoreMap;
}
public String getCallback() {
return callback;
}
public void setCallback(String callback) {
this.callback = callback;
}
public String getResultCode() {
return resultCode;
}
public void setResultCode(String resultCode) {
this.resultCode = resultCode;
}
public void put(String key, Object value) {
this.ignoreMap.put(key, value);
}
public void initPagerResult(Pager pager) {
if (pager != null) {
this.pageNo = pager.getPageNumber();
this.pageSize = pager.getPageSize();
this.totalCount = pager.getTotalCount();
this.totalPageCount = pager.getPageCount();
this.currentPageNo=pager.getPageNumber();
}
}
@Override
public String toString() {
return " Result [resultCode= " + resultCode + " , msg= " + msg + " ] ";
}
}
import java.io.Serializable;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import com.eshore.pdip.mobile.util.Pager;
import com.eshore.pdip.mobile.util.ResultCodes;
public class Result implements Serializable {
/* *
*
*/
private static final long serialVersionUID = 1L;
/* *
* ������
*/
private String resultCode = ResultCodes.INVOKE_SUCC;
private String msg;
private Object resultObj;
private List<?> resultList;
private String callback;
private int pageNo = 1; // ҳ��
private int pageSize = 10; // ÿҳ����
private int totalPageCount = 0; // ��ҳ��
private int totalCount = 0; // ������
private int currentPageNo = 1; // ������
public int getCurrentPageNo() {
return currentPageNo;
}
public void setCurrentPageNo( int currentPageNo) {
this.currentPageNo = currentPageNo;
}
private Map<String, Object> ignoreMap = new HashMap<String, Object>();
public String getMsg() {
return msg;
}
public void setMsg(String msg) {
this.msg = msg;
}
public Object getResultObj() {
return resultObj;
}
public void setResultObj(Object resultObj) {
this.resultObj = resultObj;
}
public List<?> getResultList() {
return resultList;
}
public void setResultList(List<?> resultList) {
this.resultList = resultList;
}
public int getPageNo() {
return pageNo;
}
public void setPageNo( int pageNo) {
this.pageNo = pageNo;
}
public int getPageSize() {
return pageSize;
}
public void setPageSize( int pageSize) {
this.pageSize = pageSize;
}
public int getTotalPageCount() {
return totalPageCount;
}
public void setTotalPageCount( int totalPageCount) {
this.totalPageCount = totalPageCount;
}
public int getTotalCount() {
return totalCount;
}
public void setTotalCount( int totalCount) {
this.totalCount = totalCount;
}
public Map<String, Object> getIgnoreMap() {
return ignoreMap;
}
public void setIgnoreMap(Map<String, Object> ignoreMap) {
this.ignoreMap = ignoreMap;
}
public String getCallback() {
return callback;
}
public void setCallback(String callback) {
this.callback = callback;
}
public String getResultCode() {
return resultCode;
}
public void setResultCode(String resultCode) {
this.resultCode = resultCode;
}
public void put(String key, Object value) {
this.ignoreMap.put(key, value);
}
public void initPagerResult(Pager pager) {
if (pager != null) {
this.pageNo = pager.getPageNumber();
this.pageSize = pager.getPageSize();
this.totalCount = pager.getTotalCount();
this.totalPageCount = pager.getPageCount();
this.currentPageNo=pager.getPageNumber();
}
}
@Override
public String toString() {
return " Result [resultCode= " + resultCode + " , msg= " + msg + " ] ";
}
}