/** * Copyright (c) 2018 人人开源 All rights reserved. * * https://www.renren.io * * 版权所有,侵权必究! */ package com.iailab.framework.common.page; import io.swagger.v3.oas.annotations.media.Schema; import io.swagger.v3.oas.annotations.tags.Tag; import lombok.Data; import java.io.Serializable; import java.util.List; /** * 分页工具类 * * @author Mark sunlightcs@gmail.com */ @Data @Tag(name = "分页数据") public class PageData implements Serializable { private static final long serialVersionUID = 1L; @Schema(description = "总记录数") private int total; @Schema(description = "列表数据") private List list; /** * 分页 * @param list 列表数据 * @param total 总记录数 */ public PageData(List list, long total) { this.list = list; this.total = (int)total; } }