zoukankan      html  css  js  c++  java
  • java返回分页结果集的封装

    package com.leyou.common;
    
    import java.util.List;
    
    public class PageResult<T> {
        private long total;//总条数
        private Integer totalPage;//总页数
        private List<T> list;
    
        public PageResult() {
        }
    
        public PageResult(long total, List<T> list) {
            this.total = total;
            this.list = list;
        }
    
        public PageResult(long total, Integer totalPage, List<T> list) {
            this.total = total;
            this.totalPage = totalPage;
            this.list = list;
        }
    
        public long getTotal() {
            return total;
        }
    
        public void setTotal(long total) {
            this.total = total;
        }
    
        public Integer getTotalPage() {
            return totalPage;
        }
    
        public void setTotalPage(Integer totalPage) {
            this.totalPage = totalPage;
        }
    
        public List<T> getList() {
            return list;
        }
    
        public void setList(List<T> list) {
            this.list = list;
        }
    }
    

      

  • 相关阅读:
    第二阶段冲刺04
    找水王
    第二阶段冲刺03
    第二阶段冲刺02
    第二阶段冲刺01
    学习进度12
    梦断代码阅读笔记07
    第一阶段意见评论
    学习进度11
    求素数p的原根
  • 原文地址:https://www.cnblogs.com/yscec/p/12150426.html
Copyright © 2011-2022 走看看