public final class FirstPreviousNextLastPagerRenderer
extends PagerRenderer {
protected String internalRender() {
InternalStringBuilder buf = new InternalStringBuilder();
PagerModel pagerModel = getPagerModel();
int currentPage = pagerModel.getPage();
int lastPage = pagerModel.getLastPage();
/* Page # of # First / Previous Next / Last */
buf.append(getDataGridTagModel().formatMessage(IDataGridMessageKeys.PAGER_FMT_BANNER,
new Integer[]{new Integer(currentPage + 1),
new Integer(lastPage + 1)}));
buf.append(" ");
if(currentPage > pagerModel.getFirstPage())
buf.append(buildLiveFirstLink());
else
buf.append(buildDeadFirstLink());
buf.append(" / ");
if(pagerModel.getPreviousPage() >= 0)
buf.append(buildLivePreviousLink());
else
buf.append(buildDeadPreviousLink());
buf.append(" ");
if(pagerModel.getNextPage() <= lastPage)
buf.append(buildLiveNextPageLink());
else
buf.append(buildDeadNextLink());
buf.append(" / ");