Class DirectoryIndexer

java.lang.Object
org.apache.maven.jxr.DirectoryIndexer

public class DirectoryIndexer extends Object
This class creates the navigational pages for jxr's cross-referenced source files. The navigation is inspired by javadoc, so it should have a familiar feel. Creates the following files:
  • index.html main index containing the frameset
  • overview-frame.html list of the project's packages (top left)
  • allclasses-frame.html list of all classes in the project (bottom left)
  • overview-summary.html top-level listing of the project's packages (main frame)
  • Package specific:
    • package-summary.html listing of all classes in this package (main frame)
    • package-frame.html listing of all classes in this package (bottom left)
  • Field Details

  • Constructor Details

    • DirectoryIndexer

      public DirectoryIndexer(PackageManager packageManager, String root)
      Constructor for the DirectoryIndexer object
      Parameters:
      packageManager - PackageManager for this project
      root - Path of the root output directory
  • Method Details

    • setOutputEncoding

      public void setOutputEncoding(String outputEncoding)
      OutputEncoding is the encoding of output files.
      Parameters:
      outputEncoding - output encoding
    • getOutputEncoding

      public String getOutputEncoding()
      Gets the output encoding.
      Returns:
      output encoding
    • setTemplateDir

      public void setTemplateDir(String templateDir)
      templateDir is the location of the jelly template files used to generate the navigation pages.
      Parameters:
      templateDir - location of the template directory
    • getTemplateDir

      public String getTemplateDir()
      Gets the template directory.
      Returns:
      location of the template directory
    • setWindowTitle

      public void setWindowTitle(String windowTitle)
      windowTitle is used in the output's <title> tags see the javadoc documentation for the property of the same name
      Parameters:
      windowTitle - the <title> attribute
    • getWindowTitle

      public String getWindowTitle()
      Gets the window title.
      Returns:
      window title
    • setDocTitle

      public void setDocTitle(String docTitle)
      docTitle is used as a page heading for the summary files.
      See the javadoc documentation for the property of the same name
      Parameters:
      docTitle - major page heading
    • getDocTitle

      public String getDocTitle()
      Gets the major page heading.
      Returns:
      major page heading
    • setBottom

      public void setBottom(String bottom)
      Bottom is a footer for the navigation pages, usually a copyright.
      See the javadoc documentation for the property of the same name.
      Parameters:
      bottom - page footer
    • getBottom

      public String getBottom()
      Gets the footer for the navigation pages.
      Returns:
      bottom page footer
    • process

      public void process() throws JxrException
      Does the actual indexing.
      Throws:
      JxrException - If something went wrong
    • setProperties

      private void setProperties(org.apache.velocity.app.VelocityEngine engine)
    • doVelocity

      private void doVelocity(String templateName, String outDir, org.apache.velocity.VelocityContext context, org.apache.velocity.app.VelocityEngine engine) throws JxrException
      Throws:
      JxrException
    • getProjectInfo