`
wutao8818
  • 浏览: 618183 次
  • 性别: Icon_minigender_1
  • 来自: 杭州
社区版块
存档分类
最新评论

PagedListHolder

阅读更多
org.springframework.beans.support.PagedListHolder

public class PagedListHolder
extends Object
implements Serializable

PagedListHolder is a simple state holder for handling lists of objects, separating them into pages. Page numbering starts with 0.

This is mainly targetted at usage in web UIs. Typically, an instance will be instantiated with a list of beans, put into the session, and exported as model. The properties can all be set/get programmatically, but the most common way will be data binding, i.e. populating the bean from request parameters. The getters will mainly be used by the view.

Supports sorting the underlying list via a SortDefinition implementation, available as property "sort". By default, a MutableSortDefinition instance will be used, toggling the ascending value on setting the same property again.

The data binding names have to be called "pageSize" and "sort.ascending", as expected by BeanWrapper. Note that the names and the nesting syntax match the respective JSTL EL expressions, like "myModelAttr.pageSize" and "myModelAttr.sort.ascending".

http://www.iocblog.net/project/springmvc/springmvc-856.html
分享到:
评论

相关推荐

    SSH分页(很实用)

    PagedListHolder则是一个简单的JavaBean,可以用于在Action类中存储分页信息,然后传递到视图层。 3. **Hibernate框架中的分页** Hibernate本身提供了`Criteria`和`Query`对象的分页方法,如`setFirstResult`和`...

    基于SSH框架的分页示例

    `PagedListHolder`允许开发者在内存中存储和管理分页数据,而`Pageable`接口则定义了分页查询的规范,包括页码、大小等信息。Spring还提供了`Page`接口,它不仅包含实际的数据,还提供了总条数、总页数等分页信息。...

    jsp分页标签,servlet技术实现

    分页标签库如`DisplayTag`或`PagedListHolder`提供了一种声明式的方式来实现分页功能。这些标签库通过在JSP页面中插入特定的标签,可以轻松地创建分页链接和显示分页信息。例如,`<display:table>`标签可以用来显示...

    SSH框架的简单分页

    1. **配置分页插件**:Struts2有多种分页插件可供选择,如DisplayTag、PagedListHolder等。这里我们假设使用Struts2的PagingAndSortingResult插件。在struts.xml配置文件中,添加相关的拦截器和结果类型。 2. **...

    SPRING API 2.0.CHM

    PagedListHolder PagedListSourceProvider ParameterDisposer ParameterHandlerMapping ParameterizableViewController ParameterizableViewController ParameterizedRowMapper ParameterMapper ...

Global site tag (gtag.js) - Google Analytics