DS Server

TableOfContentsCollectionAddParams Object

Object|Introduced in 29.0

Description

The method parameters for the TableOfContentsCollection.add() method.

Syntax

{
   [title: <string>],
   [hasLinks: <boolean>],
   [hasPageNumbers: <boolean>],
   [hasRightAlignedPageNumbers: <boolean>],
   [minimumStructureLevel: <number>],
   [maximumStructureLevel: <number>]
}

Examples

The following example demonstrates TableOfContentsCollectionAddParams in a practical document-editing workflow. The method parameters for the TableOfContentsCollection.add() method.

function inspectTableOfContentsCollectionAddParams(tableOfContentsCollectionAddParams) {
    console.log("title:", tableOfContentsCollectionAddParams.title);
    console.log("has links:", tableOfContentsCollectionAddParams.hasLinks);
    console.log("has page numbers:", tableOfContentsCollectionAddParams.hasPageNumbers);
    console.log("has right aligned page numbers:", tableOfContentsCollectionAddParams.hasRightAlignedPageNumbers);
}

Members

Properties

PropertyDescription
hasLinksOptional. Specifies whether each entry in the table of contents is a DocumentLink with a corresponding DocumentTarget.
hasPageNumbersOptional. Specifies whether the table of contents contains page numbers.
hasRightAlignedPageNumbersOptional. Specifies whether the page numbers in the table of contents are right-aligned.
maximumStructureLevelOptional. The minimum structure level for this table of contents.
minimumStructureLevelOptional. The maximum structure level for this table of contents.
titleOptional. The title for the table of contents.