Compact Class For Java – CCPagination


Compact Class is a collection of common functions and classes that can make your code more concise, fast, and precise.

utility

Class CCPagination

java.lang.Object

extended by

utility.CCPagination

public final class CCPaginationextends java.lang.Object

CCOption is a class to help making pagination.

Since:
10.03.17
Version:
12.03.17
Author:
Yosua Onesimus


Field Detail

DATA_PER_PAGE

public static int DATA_PER_PAGE
DATA_PER_PAGE

 


DIFF_PAGE

public static int DIFF_PAGE
DIFF_PAGE

 


Constructor Detail

CCPagination

public CCPagination(int totalData,
                    int dataPerPage)
Parameters:
totalData
dataPerPage

CCPagination

public CCPagination(int totalData)
Parameters:
totalData

CCPagination

public CCPagination()


Method Detail

getPage

public long getPage(int dataNumber)
Parameters:
dataNumber

Returns:
page

getDataPerPage

public long getDataPerPage()
Returns:
data per page

setDataPerPage

public void setDataPerPage(int dataPerPage)
Parameters:
dataPerPage

getTotalData

public long getTotalData()
Returns:
total data

setTotalData

public void setTotalData(long totalData)
Parameters:
totalData

getCurrentPage

public long getCurrentPage()
Returns:
current page

setCurrentPage

public void setCurrentPage(long currentPage)
Parameters:
currentPage

getTotalPage

public long getTotalPage()
Returns:
total page

getPages

public java.util.List getPages()
Returns:
pages

getFirstResult

public long getFirstResult()
Returns:
first result

getMaxResults

public long getMaxResults()
Returns:
max result
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: