getOutline

Returns list of top-level (outline / table-of-contents) bookmarks. Bookmarks are organized in a tree-like structure and can have children. Note that this may take a while and should not be called on the main thread. If you want a quick check for whether document has outline, use hasOutline.

Note: When this document is a compound document, calling this method will only ever return the outline of the first document source.

Return

List of top-level bookmarks. If no outline elements exist, the returned list will be empty.