public class LazyLoad extends WebPage {
public LazyLoad() {
IColumn[] columns = new IColumn[] {
new PropertyColumn(new Model("col1"), "intValue"),
new PropertyColumn(new Model("col2"), "class") };
ISortableDataProvider dataProvider = new SortableDataProvider() {
public int size() {
return 300000;
}
public IModel model(Object object) {
return new Model((Integer) object);
}
public Iterator iterator(int first, int count) {
return loadEntriesFromDatabase(first, count).iterator();
}
private List<Integer> loadEntriesFromDatabase(int first, int count) {
List<Integer> items = new ArrayList<Integer>();
for (int i = 0; i < count; i++) {
items.add(new Integer(first + i));
}
return items;
}
};
DefaultDataTable t = new DefaultDataTable("t", columns, dataProvider, 3);
add(t);
}
}
Publisher: CRC Press (Taylor and Francis Group)Cat. #: 2880
ISBN: 9780849328800
ISBN 10: 0849328802
Publication Date: March 27, 2009
Number of Pages: 395
T. Reps, S. Horwitz, and M. Sagiv. Proceedings of the 22Nd ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages
, page 49--61. New York, NY, USA, ACM, (1995)
X. Li, B. Liu, and S. Ng. Proceedings of the 2010 Conference on Empirical Methods in Natural Language Processing
, page 218--228. Stroudsburg, PA, USA, Association for Computational Linguistics, (2010)
B. Plank, and G. van Noord. Proceedings of the 2010 Workshop on NLP and Linguistics: Finding the Common Ground
, page 25--33. Stroudsburg, PA, USA, Association for Computational Linguistics, (2010)
V. Spitkovsky, H. Alshawi, and D. Jurafsky. NIPS 2009 Workshop on Grammar Induction, Representation of Language and Language Learning
, Whistler, Canada, (December 2009)