GWTApplication.client
Class SearchResultFormatter.DisplaySearchResultsIncrementalCommand

java.lang.Object
  extended by GWTApplication.client.SearchResultFormatter.DisplaySearchResultsIncrementalCommand
All Implemented Interfaces:
com.google.gwt.user.client.IncrementalCommand
Enclosing class:
SearchResultFormatter

private class SearchResultFormatter.DisplaySearchResultsIncrementalCommand
extends java.lang.Object
implements com.google.gwt.user.client.IncrementalCommand

This is an incremental command which is used to display the search results so that the browser does not simply lock up whilst the results are being displayed. Although it is not possible to thread GWT applications, this works like a timer and breaks the work up such that the browser will respond to the user whilst it is building the search panel. This is important as to build the FlexTable which contains the details of the search results takes a lot of time and I'm sure that the user will not appreciate having to wait for 30 seconds until his search results are displayed.

Version:
$Id: SearchResultFormatter.java,v 1.26 2007/12/17 12:26:40 cb Exp $
Author:
Craige Bevil

Field Summary
private  int currentRow
          This is the current row in the search result table into which we put the next search result
private  int numberOfResultsToAdd
          This is the number of search results that we need to add to the search panel
private  int numberOfRowsAdded
          This is the number of search results which have been added to the search panel
private  java.util.ArrayList searchResults
          This is the list of search results which are to be displayed in the search result panel
 
Constructor Summary
SearchResultFormatter.DisplaySearchResultsIncrementalCommand(java.util.ArrayList searchResults)
          This is the constructor
 
Method Summary
 boolean execute()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

numberOfResultsToAdd

private int numberOfResultsToAdd
This is the number of search results that we need to add to the search panel


numberOfRowsAdded

private int numberOfRowsAdded
This is the number of search results which have been added to the search panel


searchResults

private java.util.ArrayList searchResults
This is the list of search results which are to be displayed in the search result panel


currentRow

private int currentRow
This is the current row in the search result table into which we put the next search result

Constructor Detail

SearchResultFormatter.DisplaySearchResultsIncrementalCommand

SearchResultFormatter.DisplaySearchResultsIncrementalCommand(java.util.ArrayList searchResults)
This is the constructor

Method Detail

execute

public boolean execute()
Specified by:
execute in interface com.google.gwt.user.client.IncrementalCommand