Interface TableOfContents

All Superinterfaces:
Component, ComponentExporter

public interface TableOfContents extends Component
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static enum 
    Defines the possible heading levels for table of contents corresponding to 'h1' till 'h6'
    static enum 
    Defines the possible list types for table of contents
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
    Name of the configuration policy property, if set, titles with those class names or contained within elements of the indicated class names will be ignored.
    static final String
    Name of the configuration policy property, if set, only titles with those class names or contained within elements of the indicated class names will be considered
    static final String
    Name of the optional resource property that stores the list type of table of contents.
    static final String
    Name of the configuration policy property that controls whether the author should be able to choose the list type or not.
    static final String
    Name of the configuration policy property that controls whether the author should be able to choose the minimum title level to report in the table of contents.
    static final String
    Name of the configuration policy property that controls whether the author should be able to choose the maximum title level to report in the table of contents.
    static final String
    Name of the optional resource property that stores the minimum title level to generate table of contents.
    static final String
    Name of the optional resource property that stores the maximum title level to generate table of contents.
    static final String
    HTML class name added on the final TOC render.
    static final String
    HTML data attribute added on the TOC placeholder containing the configured ignore classes of the TOC as a comma separated list.
    static final String
    HTML data attribute added on the TOC placeholder containing the configured include classes of the TOC as a comma separated list.
    static final String
    HTML data attribute added on the TOC placeholder containing the configured list type of the TOC .
    static final String
    HTML data attribute added on the TOC placeholder containing the configured start level of the TOC.
    static final String
    HTML data attribute added on the TOC placeholder containing the configured stop level of the TOC.
    static final String
    HTML class name added on the TOC placeholder rendered by the component's HTL.
    static final String
    HTML class name added on the TOC template placeholder which is only viewed in EDIT mode on page editor.

    Fields inherited from interface com.adobe.cq.wcm.core.components.models.Component

    PN_ID
  • Method Summary

    Modifier and Type
    Method
    Description
    default String[]
    Returns an array of all ignore class names set in configuration policy
    default String[]
    Returns an array of all include class names set in configuration policy
    Returns the configured list type taking into account the configuration policy
    Returns the start level taking into account the configuration policy
    Returns the stop level taking into account the configuration policy

    Methods inherited from interface com.adobe.cq.wcm.core.components.models.Component

    getAppliedCssClasses, getData, getExportedType, getId
  • Field Details

    • PN_LIST_TYPE

      static final String PN_LIST_TYPE
      Name of the optional resource property that stores the list type of table of contents.
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
      See Also:
    • PN_START_LEVEL

      static final String PN_START_LEVEL
      Name of the optional resource property that stores the minimum title level to generate table of contents.
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
      See Also:
    • PN_STOP_LEVEL

      static final String PN_STOP_LEVEL
      Name of the optional resource property that stores the maximum title level to generate table of contents.
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
      See Also:
    • PN_RESTRICT_LIST_TYPE

      static final String PN_RESTRICT_LIST_TYPE
      Name of the configuration policy property that controls whether the author should be able to choose the list type or not.
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
      See Also:
    • PN_RESTRICT_START_LEVEL

      static final String PN_RESTRICT_START_LEVEL
      Name of the configuration policy property that controls whether the author should be able to choose the minimum title level to report in the table of contents.
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
      See Also:
    • PN_RESTRICT_STOP_LEVEL

      static final String PN_RESTRICT_STOP_LEVEL
      Name of the configuration policy property that controls whether the author should be able to choose the maximum title level to report in the table of contents.
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
      See Also:
    • PN_INCLUDE_CLASSES

      static final String PN_INCLUDE_CLASSES
      Name of the configuration policy property, if set, only titles with those class names or contained within elements of the indicated class names will be considered
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
      See Also:
    • PN_IGNORE_CLASSES

      static final String PN_IGNORE_CLASSES
      Name of the configuration policy property, if set, titles with those class names or contained within elements of the indicated class names will be ignored.
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
      See Also:
    • TOC_CONTENT_CLASS

      static final String TOC_CONTENT_CLASS
      HTML class name added on the final TOC render. It contains the numbered/bulleted nested list of contents of the page.
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
      See Also:
    • TOC_PLACEHOLDER_CLASS

      static final String TOC_PLACEHOLDER_CLASS
      HTML class name added on the TOC placeholder rendered by the component's HTL. It contains all the TOC configuration properties (from its resource and configuration policy properties) as data attributes.
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
      See Also:
    • TOC_TEMPLATE_PLACEHOLDER_CLASS

      static final String TOC_TEMPLATE_PLACEHOLDER_CLASS
      HTML class name added on the TOC template placeholder which is only viewed in EDIT mode on page editor.
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
      See Also:
    • TOC_DATA_ATTR_LIST_TYPE

      static final String TOC_DATA_ATTR_LIST_TYPE
      HTML data attribute added on the TOC placeholder containing the configured list type of the TOC .
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
      See Also:
    • TOC_DATA_ATTR_START_LEVEL

      static final String TOC_DATA_ATTR_START_LEVEL
      HTML data attribute added on the TOC placeholder containing the configured start level of the TOC.
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
      See Also:
    • TOC_DATA_ATTR_STOP_LEVEL

      static final String TOC_DATA_ATTR_STOP_LEVEL
      HTML data attribute added on the TOC placeholder containing the configured stop level of the TOC.
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
      See Also:
    • TOC_DATA_ATTR_INCLUDE_CLASSES

      static final String TOC_DATA_ATTR_INCLUDE_CLASSES
      HTML data attribute added on the TOC placeholder containing the configured include classes of the TOC as a comma separated list.
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
      See Also:
    • TOC_DATA_ATTR_IGNORE_CLASSES

      static final String TOC_DATA_ATTR_IGNORE_CLASSES
      HTML data attribute added on the TOC placeholder containing the configured ignore classes of the TOC as a comma separated list.
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
      See Also:
  • Method Details

    • getListType

      default TableOfContents.ListType getListType()
      Returns the configured list type taking into account the configuration policy
      Returns:
      list type, default is 'unordered'
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
    • getStartLevel

      default TableOfContents.HeadingLevel getStartLevel()
      Returns the start level taking into account the configuration policy
      Returns:
      start level, default is '1'
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
    • getStopLevel

      default TableOfContents.HeadingLevel getStopLevel()
      Returns the stop level taking into account the configuration policy
      Returns:
      stop level, default is '6'
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
    • getIncludeClasses

      default String[] getIncludeClasses()
      Returns an array of all include class names set in configuration policy
      Returns:
      array of include class names, 'null' if not set
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0
    • getIgnoreClasses

      default String[] getIgnoreClasses()
      Returns an array of all ignore class names set in configuration policy
      Returns:
      array of ignore class names, 'null' if not set
      Since:
      com.adobe.cq.wcm.core.components.models.tableofcontents 1.0