parameters: (headlines, hyperlink=True, top_link=False, no_toc_header=False)
return_statement: return processed
docstring: Creates the table of contents from the headline list
      that was returned by the tagAndCollect function.
  
      Keyword Arguments:
          headlines: list of lists
              e.g., ['Some header lvl3', 'some-header-lvl3', 3]
          hyperlink: Creates hyperlinks in Markdown format if True,
              e.g., '- [Some header lvl1](#some-header-lvl1)'
          top_link: if True, add a id tag for linking the table
              of contents itself (for the back-to-top-links)
          no_toc_header: suppresses TOC header if True.
  
      Returns  a list of headlines for a table of contents
      in Markdown format,
      e.g., ['        - [Some header lvl3](#some-header-lvl3)', ...]
docstring_summary: Creates the table of contents from the headline list
      that was returned by the tagAndCollect function.
docstring_tokens: Creates the table of contents from the headline list that was returned by the tagAndCollect function .
function: def createToc(headlines, hyperlink=True, top_link=False, no_toc_header=False):
      """
      Creates the table of contents from the headline list
      that was returned by the tagAndCollect function.
  
      Keyword Arguments:
          headlines: list of lists
              e.g., ['Some header lvl3', 'some-header-lvl3', 3]
          hyperlink: Creates hyperlinks in Markdown format if True,
              e.g., '- [Some header lvl1](#some-header-lvl1)'
          top_link: if True, add a id tag for linking the table
              of contents itself (for the back-to-top-links)
          no_toc_header: suppresses TOC header if True.
  
      Returns  a list of headlines for a table of contents
      in Markdown format,
      e.g., ['        - [Some header lvl3](#some-header-lvl3)', ...]
  
      """
      processed = []
      if not no_toc_header:
          if top_link:
              processed.append('<a class="mk-toclify" id="table-of-contents"></a>\n')
          processed.append(contentTitle + '<br>')
  
      for line in headlines:
          if hyperlink:
              item = '[%s](#%s)' % (line[0], line[1])
          else:
              item = '%s- %s' % ((line[2]-1)*'    ', line[0])
          processed.append(item + '<br>')
      processed.append('\n')
      return processed
function_tokens: def createToc ( headlines , hyperlink = True , top_link = False , no_toc_header = False ) : processed = [ ] if not no_toc_header : if top_link : processed . append ( '<a class="mk-toclify" id="table-of-contents"></a>\n' ) processed . append ( contentTitle + '<br>' ) for line in headlines : if hyperlink : item = '[%s](#%s)' % ( line [ 0 ] , line [ 1 ] ) else : item = '%s- %s' % ( ( line [ 2 ] - 1 ) * '    ' , line [ 0 ] ) processed . append ( item + '<br>' ) processed . append ( '\n' ) return processed