T
- row/item model object typepublic class DataProviderAdapter<T,S> extends Object implements IDataSource<T>
IDataProvider
in an AbstractGrid
.
The adapter also supports sortable data providers.IDataSource.IQuery, IDataSource.IQueryResult<T>
Constructor and Description |
---|
DataProviderAdapter(org.apache.wicket.markup.repeater.data.IDataProvider<T> dataProvider)
Creates a new
DataProviderAdapter instance. |
Modifier and Type | Method and Description |
---|---|
void |
detach() |
org.apache.wicket.model.IModel<T> |
model(T object)
Allows wrapping the object in a model which will be set as model of the appropriate row.
|
void |
query(IDataSource.IQuery query,
IDataSource.IQueryResult<T> result)
Implementation of this method should load subset of the data specified by
query.getFrom() and query.getCount() . |
public DataProviderAdapter(org.apache.wicket.markup.repeater.data.IDataProvider<T> dataProvider)
DataProviderAdapter
instance.dataProvider
- IDataProvider
instancepublic void detach()
detach
in interface org.apache.wicket.model.IDetachable
public org.apache.wicket.model.IModel<T> model(T object)
model
in interface IDataSource<T>
public void query(IDataSource.IQuery query, IDataSource.IQueryResult<T> result)
query.getFrom()
and query.getCount()
. Also if the total item count
can be determined, it should be passed to result
.query
in interface IDataSource<T>
query
- Specified the amount and position of items to be queriedresult
- Allows to set the total item count and result itemsCopyright © 2015. All rights reserved.