org.exoplatform.services.wcm.webcontent
Class TOCGeneratorService

java.lang.Object
  extended by org.exoplatform.services.wcm.webcontent.TOCGeneratorService

public class TOCGeneratorService
extends java.lang.Object

Created by The eXo Platform SAS Author : DANG TAN DUNG dzungdev@gmail.com Jul 29, 2008


Nested Class Summary
 class TOCGeneratorService.Heading
          The Class Heading.
 
Constructor Summary
TOCGeneratorService()
           
 
Method Summary
 java.util.List<TOCGeneratorService.Heading> extractHeadings(org.exoplatform.services.html.HTMLDocument document)
          Extract headings.
 java.lang.String getTOC(javax.jcr.Node htmlNode)
          Gets the tOC.
 void updateTOC(javax.jcr.Node htmlFile, java.util.List<TOCGeneratorService.Heading> headingList)
          Update toc.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TOCGeneratorService

public TOCGeneratorService()
Method Detail

updateTOC

public void updateTOC(javax.jcr.Node htmlFile,
                      java.util.List<TOCGeneratorService.Heading> headingList)
               throws java.lang.Exception
Update toc.

Parameters:
htmlFile - the html file
headingList - the heading list
Throws:
java.lang.Exception - the exception

getTOC

public java.lang.String getTOC(javax.jcr.Node htmlNode)
                        throws java.lang.Exception
Gets the tOC.

Parameters:
htmlNode - the html node
Returns:
the tOC
Throws:
java.lang.Exception - the exception

extractHeadings

public java.util.List<TOCGeneratorService.Heading> extractHeadings(org.exoplatform.services.html.HTMLDocument document)
                                                            throws java.lang.Exception
Extract headings.

Parameters:
document - the document
Returns:
the list< heading>
Throws:
java.lang.Exception - the exception


Copyright © 2011 eXo Platform SAS. All Rights Reserved.