package com.yd.util.page;

import java.util.ArrayList;
import java.util.List;


public class PaginationInfo {
	private Integer number;
	private Integer size;
	private Long totalElements;
	private Integer totalPages;
	private Integer numberOfElements;
	private List<SortInfo> sortInfo;
	private String noLimitFlag;
	
	public void addOrderInfo(String isASC, String orderProperty){
		if(this.sortInfo == null){
			this.sortInfo = new ArrayList<SortInfo>();
		}
		SortInfo orderInfoItem = new SortInfo(isASC,orderProperty);
		this.sortInfo.add(orderInfoItem);
	}
	public void addOrderInfo(SortInfo orderInfoItem){
		if(this.sortInfo == null){
			this.sortInfo = new ArrayList<SortInfo>();
		}
		this.sortInfo.add(orderInfoItem);
	}
	public Integer getNumber() {
		return number;
	}

	public void setNumber(Integer number) {
		this.number = number;
	}

	public Integer getSize() {
		return size;
	}

	public void setSize(Integer size) {
		this.size = size;
	}

	public Long getTotalElements() {
		return totalElements;
	}

	public void setTotalElements(Long totalElements) {
		this.totalElements = totalElements;
	}

	public Integer getTotalPages() {
		return totalPages;
	}

	public void setTotalPages(Integer totalPages) {
		this.totalPages = totalPages;
	}

	public Integer getNumberOfElements() {
		return numberOfElements;
	}

	public void setNumberOfElements(Integer numberOfElements) {
		this.numberOfElements = numberOfElements;
	}

	public List<SortInfo> getSortInfo() {
		return sortInfo;
	}

	public void setSortInfo(List<SortInfo> sortInfo) {
		this.sortInfo = sortInfo;
	}
	public String getNoLimitFlag() {
		return noLimitFlag;
	}
	public void setNoLimitFlag(String noLimitFlag) {
		this.noLimitFlag = noLimitFlag;
	}
}
