Package org.jamwiki.utils

Examples of org.jamwiki.utils.Pagination


  /**
   *
   */
  private void recentChanges(HttpServletRequest request, ModelAndView next, WikiPageInfo pageInfo) throws Exception {
    String virtualWiki = pageInfo.getVirtualWikiName();
    Pagination pagination = ServletUtil.loadPagination(request, next);
    List<RecentChange> changes = WikiBase.getDataHandler().getRecentChanges(virtualWiki, pagination, true);
    next.addObject("changes", changes);
    next.addObject("numChanges", changes.size());
    pageInfo.setPageTitle(new WikiMessage("recentchanges.title"));
    pageInfo.setContentJsp(JSP_RECENT_CHANGES);
View Full Code Here


  /**
   *
   */
  private void viewCategories(HttpServletRequest request, ModelAndView next, WikiPageInfo pageInfo) throws Exception {
    String virtualWiki = pageInfo.getVirtualWikiName();
    Pagination pagination = ServletUtil.loadPagination(request, next);
    Iterable<Category> categoryObjects = WikiBase.getDataHandler().getAllCategories(virtualWiki, pagination);
    LinkedHashMap<String, String> categories = new LinkedHashMap<String, String>();
    for (Category category : categoryObjects) {
      String key = category.getName();
      String value = key.substring(NamespaceHandler.NAMESPACE_CATEGORY.length() + NamespaceHandler.NAMESPACE_SEPARATOR.length());
View Full Code Here

  /**
   *
   */
  private void view(HttpServletRequest request, ModelAndView next, WikiPageInfo pageInfo) throws Exception {
    String virtualWiki = pageInfo.getVirtualWikiName();
    Pagination pagination = ServletUtil.loadPagination(request, next);
    WikiUserDetails userDetails = ServletUtil.currentUserDetails();
    if (userDetails.hasRole(RoleImpl.ROLE_ANONYMOUS)) {
      throw new WikiException(new WikiMessage("watchlist.error.loginrequired"));
    }
    WikiUser user = ServletUtil.currentWikiUser();
View Full Code Here

      throw new WikiException(new WikiMessage("common.exception.notopic"));
    }
    pageInfo.setContentJsp(JSP_HISTORY);
    pageInfo.setTopicName(topicName);
    pageInfo.setPageTitle(new WikiMessage("history.title", topicName));
    Pagination pagination = ServletUtil.loadPagination(request, next);
    List<RecentChange> changes = WikiBase.getDataHandler().getTopicHistory(
        virtualWiki, topicName, pagination, true);
    if (changes != null && changes.size() > 0) {
      next.addObject("changes", changes);
      next.addObject("numChanges", changes.size());
View Full Code Here

TOP

Related Classes of org.jamwiki.utils.Pagination

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.