com.google.gwt.user.cellview.client
Class SimplePager<T>

java.lang.Object
  extended by com.google.gwt.user.client.ui.UIObject
      extended by com.google.gwt.user.client.ui.Widget
          extended by com.google.gwt.user.client.ui.Composite
              extended by com.google.gwt.user.cellview.client.AbstractPager<T>
                  extended by com.google.gwt.user.cellview.client.SimplePager<T>
Type Parameters:
T - the type of the PagingListView being controlled
All Implemented Interfaces:
HasHandlers, EventListener, PagingListView.Pager<T>

public class SimplePager<T>
extends AbstractPager<T>

A pager for controlling a PagingListView that only supports simple page navigation.


Nested Class Summary
static interface SimplePager.Resources
          A ClientBundle that provides images for this widget.
static interface SimplePager.Style
          Styles used by this widget.
static class SimplePager.TextLocation
          The location of the text relative to the paging buttons.
 
Nested classes/interfaces inherited from class com.google.gwt.user.client.ui.UIObject
UIObject.DebugIdImpl, UIObject.DebugIdImplEnabled
 
Field Summary
 
Fields inherited from class com.google.gwt.user.client.ui.UIObject
DEBUG_ID_PREFIX
 
Constructor Summary
SimplePager(PagingListView<T> view)
          Construct a SimplePager.
SimplePager(PagingListView<T> view, SimplePager.TextLocation location)
          Construct a SimplePager with the specified text location.
SimplePager(PagingListView<T> view, SimplePager.TextLocation location, SimplePager.Resources resources, boolean showFastForwardButton, int fastForwardPages, boolean showLastPageButton)
          Construct a SimplePager with the specified resources.
 
Method Summary
 void onRangeOrSizeChanged(PagingListView<T> listView)
           
 void startLoading()
          Let the page know that the table is loading.
 
Methods inherited from class com.google.gwt.user.cellview.client.AbstractPager
firstPage, getPage, getPageCount, getPageSize, getPageStart, getPagingListView, hasNextPage, hasNextPages, hasPage, hasPreviousPage, hasPreviousPages, isRangeLimited, lastPage, lastPageStart, nextPage, previousPage, setPage, setPageSize, setPageStart, setRangeLimited
 
Methods inherited from class com.google.gwt.user.client.ui.Composite
isAttached, onBrowserEvent
 
Methods inherited from class com.google.gwt.user.client.ui.Widget
fireEvent, getLayoutData, getParent, removeFromParent, setLayoutData, sinkEvents
 
Methods inherited from class com.google.gwt.user.client.ui.UIObject
addStyleDependentName, addStyleName, ensureDebugId, ensureDebugId, getAbsoluteLeft, getAbsoluteTop, getElement, getOffsetHeight, getOffsetWidth, getStyleName, getStylePrimaryName, getTitle, isVisible, isVisible, removeStyleDependentName, removeStyleName, setHeight, setPixelSize, setSize, setStyleDependentName, setStyleName, setStyleName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, toString, unsinkEvents
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SimplePager

public SimplePager(PagingListView<T> view)
Construct a SimplePager.

Parameters:
view - the PagingListView to page

SimplePager

@UiConstructor
public SimplePager(PagingListView<T> view,
                                 SimplePager.TextLocation location)
Construct a SimplePager with the specified text location.

Parameters:
view - the PagingListView to page
location - the location of the text relative to the buttons

SimplePager

public SimplePager(PagingListView<T> view,
                   SimplePager.TextLocation location,
                   SimplePager.Resources resources,
                   boolean showFastForwardButton,
                   int fastForwardPages,
                   boolean showLastPageButton)
Construct a SimplePager with the specified resources.

Parameters:
view - the PagingListView to page
location - the location of the text relative to the buttons
resources - the SimplePager.Resources to use
showFastForwardButton - if true, show a fast-forward button that advances by a larger increment than a single page
fastForwardPages - the number of pages to fast forward
showLastPageButton - if true, show a button to go the the last page
Method Detail

onRangeOrSizeChanged

public void onRangeOrSizeChanged(PagingListView<T> listView)
Specified by:
onRangeOrSizeChanged in interface PagingListView.Pager<T>
Overrides:
onRangeOrSizeChanged in class AbstractPager<T>

startLoading

public void startLoading()
Let the page know that the table is loading. Call this method to clear all data from the table and hide the current range when new data is being loaded into the table.