|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
ObjectDataGridConfig
public abstract class DataGridConfig
Abstract class used by the data grid to create model objects used for state
management and rendering. This abstraction exists in order to allow the data grid's
implementation to be configurable. Various data grid implementation classes are exposed
here including sorting, filtering, and paging. In addition, classes such as the
PagerRenderer
and StyleModel
are created by subclasses in order to provide
a data grid specific implementation of pager UI or style support.
By default, DataGridConfig implementations are not thread safe, but custom implementations are free to store instance state as long as the DataGridConfig object lifetimes are managed in user code.
A specific DataGridConfig object can be created and passed to a data grid via the
data grid's
DataGrid.setDataGridConfig(DataGridConfig)
method.
Constructor Summary | |
---|---|
DataGridConfig()
|
Method Summary | |
---|---|
abstract DataGridState |
createDataGridState()
Create a DataGridState instance that will be used to store the state for a data grid. |
abstract Filter |
createFilter()
Create a concrete Filter implementation for a data grid. |
abstract FilterModel |
createFilterModel(List filters)
Create a FilterModel instance used to store the Filter state for a data grid. |
abstract PagerModel |
createPagerModel()
Create a PagerModel instance used to store the current paging state for a data grid. |
abstract Sort |
createSort()
Create a concrete Sort implementation for a data grid. |
abstract SortModel |
createSortModel(List sorts)
Create a SortModel instance used to store the Sort state for a data grid. |
abstract DataGridStateCodec |
createStateCodec(ServletRequest request,
String gridName)
Create a DataGridStateCodec instance used to obtain services for handling data grid state. |
abstract PagerRenderer |
getDefaultPagerRenderer()
Create a concrete PagerRenderer implementation that will be used to render the pager
in the absence of an alternate pager renderer. |
abstract DataGridResourceProvider |
getDefaultResourceProvider()
Create the default DataGridResourceProvider . |
abstract DataGridResourceProvider |
getResourceProvider(String resourceBundle)
Create a DataGridConfig-specific implementation of a DataGridResourceProvider . |
abstract StyleModel |
getStyleModel(String name,
String classPrefix)
Create a StyleModel used by a data grid to render styles onto various HTML markup elements
generated by a data grid. |
Methods inherited from class Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DataGridConfig()
Method Detail |
---|
public abstract DataGridState createDataGridState()
Create a DataGridState
instance that will be used to store the state for a data grid. This
method will be called only when a DataGridState object needs to be manufactured by a data grid tag.
DataGridState
object for a data grid.public abstract Sort createSort()
Create a concrete Sort
implementation for a data grid. When the sort state of a data grid
is created, this Sort
instance will contain a single sort.
Sort
instancepublic abstract SortModel createSortModel(List sorts)
Create a SortModel
instance used to store the Sort
state for a data grid.
sorts
- the current List
of sorts for a data grid
SortModel
public abstract Filter createFilter()
Create a concrete Filter
implementation for a data grid. When the filter state of a data grid
is created, this Filter
instance will contain a single filter.
Filter
instancepublic abstract FilterModel createFilterModel(List filters)
Create a FilterModel
instance used to store the Filter
state for a data grid.
filters
- the current List
of filters for a data grid
FilterModel
public abstract PagerModel createPagerModel()
Create a PagerModel
instance used to store the current paging state for a data grid.
PagerModel
public abstract DataGridStateCodec createStateCodec(ServletRequest request, String gridName)
Create a DataGridStateCodec
instance used to obtain services for handling data grid state.
request
- the current ServletRequest
gridName
- the name of a data grid whose DataGridStateCodec
to obtain
DataGridStateCodec
public abstract DataGridResourceProvider getDefaultResourceProvider()
Create the default DataGridResourceProvider
. A resource provider is an implementation of
the DataGridResourceProvider
which is used during data grid rendering to obtain strings
for messages, paths, etc. The default resource provider simply exposes the default data grid
messages stored in the properties file located at:
org.apache.beehive.netui.databinding.datagrid.runtime.util.data-grid-default.properties
DataGridResourceProvider
public abstract DataGridResourceProvider getResourceProvider(String resourceBundle)
Create a DataGridConfig-specific implementation of a DataGridResourceProvider
. The DataGridConfig
instance should use the provided resource bundle path to create a DataGridResourceProvider
which
will expose those messages into the data grid for rendering.
resourceBundle
- the resource bundle to use for grid messages
DataGridResourceProvider
public abstract StyleModel getStyleModel(String name, String classPrefix)
Create a StyleModel
used by a data grid to render styles onto various HTML markup elements
generated by a data grid.
name
- the name of a style type to support. This name can vary by DataGridConfig
implementation
subclasses may use this value to configure the type of StyleModel
returned to the caller.classPrefix
- an optional prefix to use when generating style class names
StyleModel
public abstract PagerRenderer getDefaultPagerRenderer()
Create a concrete PagerRenderer
implementation that will be used to render the pager
in the absence of an alternate pager renderer.
PagerRenderer
used to render a paging user interface
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |