Class PageFilter

java.lang.Object
com.day.cq.wcm.api.PageFilter
All Implemented Interfaces:
Filter<Page>

public class PageFilter extends Object implements Filter<Page>
Implements a simple page filter that checks for invalid and hidden pages.
  • Constructor Details

    • PageFilter

      public PageFilter()
      creates a default filter that excludes invalid and hidden pages.
    • PageFilter

      public PageFilter(WCMMode mode)
      creates a default filter that excludes hidden pages. invalid pages are only excluded if the WCM mode is WCMMode.DISABLED.
      Parameters:
      mode - the WCM mode
    • PageFilter

      public PageFilter(ServletRequest req)
      creates a default filter that excludes hidden pages. invalid pages are only excluded if the WCM mode is WCMMode.DISABLED.
      Parameters:
      req - request to read the WCM mode from
    • PageFilter

      public PageFilter(boolean includeInvalid, boolean includeHidden)
      creates a filter.
      Parameters:
      includeInvalid - if true invalid pages are included.
      includeHidden - if true hidden pages are included.
  • Method Details

    • includes

      public boolean includes(Page page)
      Checks if the given element is included in this filter.
      Specified by:
      includes in interface Filter<Page>
      Parameters:
      page - the element to check
      Returns:
      true if the element is included; false otherwise.
    • isIncludeInvalid

      public boolean isIncludeInvalid()
      Checks if invalid pages are included.
      Returns:
      true if invalid pages are included.
    • isIncludeHidden

      public boolean isIncludeHidden()
      Checks if hidden pages are included
      Returns:
      true if hidden pages are included.