org.gradle.api.tasks.javadoc

## Class Groovydoc

- java.lang.Object
- - org.gradle.api.internal.AbstractTask
  - - org.gradle.api.DefaultTask
    - - org.gradle.api.internal.ConventionTask
      - - org.gradle.api.tasks.SourceTask
        - - org.gradle.api.tasks.javadoc.Groovydoc

- All Implemented Interfaces:
    Comparable<Task>, org.gradle.api.internal.DynamicObjectAware, org.gradle.api.internal.IConventionAware, org.gradle.api.internal.TaskInternal, ExtensionAware, Task, PatternFilterable, org.gradle.util.Configurable<Task>

      public class Groovydoc
      extends SourceTask

  Generates HTML API documentation for Groovy source, and optionally, Java source.

  This task uses Groovy's Groovydoc tool to generate the API documentation. Please note that the Groovydoc tool has some severe limitations at the moment (for example no doc for properties comments). The version of the Groovydoc that is used, is the one from the Groovy defined in the build script. Please note also, that the Groovydoc tool prints to System.out for many of its statements and does circumvents our logging currently.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `Groovydoc.Link` A Link class represent a link between groovydoc/javadoc output and url.

    - ### Nested classes/interfaces inherited from interface org.gradle.api.Task

      `Task.Namer`

  - ### Field Summary

    - ### Fields inherited from interface org.gradle.api.Task

      `TASK_ACTION, TASK_DEPENDS_ON, TASK_DESCRIPTION, TASK_GROUP, TASK_NAME, TASK_OVERWRITE, TASK_TYPE`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `Groovydoc()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected void` | `generate()`
    `org.gradle.api.tasks.javadoc.AntGroovydoc` | `getAntGroovydoc()`
    `FileCollection` | `getClasspath()` Returns the classpath used to locate classes referenced by the documented sources.
    `File` | `getDestinationDir()` Returns the directory to generate the documentation into.
    `String` | `getDocTitle()` Returns the title for the package index(first) page.
    `String` | `getFooter()` Returns the html footer for each page.
    `FileCollection` | `getGroovyClasspath()` Returns the classpath containing the Groovy library to be used.
    `String` | `getHeader()` Returns the html header for each page.
    `Set<Groovydoc.Link>` | `getLinks()` Returns the links to groovydoc/javadoc output at the given URL.
    `String` | `getOverview()` Returns a html file to be used for overview documentation.
    `String` | `getWindowTitle()` Returns the browser window title for the documentation.
    `boolean` | `isIncludePrivate()` Returns whether to include all classes and members (i.e.
    `boolean` | `isUse()` Returns whether to create class and package usage pages.
    `void` | `link(String url, String... packages)` Add links to groovydoc/javadoc output at the given URL.
    `void` | `setAntGroovydoc(org.gradle.api.tasks.javadoc.AntGroovydoc antGroovydoc)`
    `void` | `setClasspath(FileCollection classpath)` Sets the classpath used to locate classes referenced by the documented sources.
    `void` | `setDestinationDir(File destinationDir)` Sets the directory to generate the documentation into.
    `void` | `setDocTitle(String docTitle)` Sets title for the package index(first) page (optional).
    `void` | `setFooter(String footer)` Sets footer text for each page (optional).
    `void` | `setGroovyClasspath(FileCollection groovyClasspath)` Sets the classpath containing the Groovy library to be used.
    `void` | `setHeader(String header)` Sets header text for each page (optional).
    `void` | `setIncludePrivate(boolean includePrivate)` Sets whether to include all classes and members (i.e.
    `void` | `setLinks(Set<Groovydoc.Link> links)` Sets links to groovydoc/javadoc output at the given URL.
    `void` | `setOverview(String overview)` Sets a html file to be used for overview documentation (optional).
    `void` | `setUse(boolean use)` Sets whether to create class and package usage pages.
    `void` | `setWindowTitle(String windowTitle)` Sets the browser window title for the documentation.

    - ### Methods inherited from class org.gradle.api.tasks.SourceTask

      `exclude, exclude, exclude, exclude, getDefaultSource, getExcludes, getIncludes, getSource, include, include, include, include, setExcludes, setIncludes, setSource, source`

    - ### Methods inherited from class org.gradle.api.internal.ConventionTask

      `conventionMapping, conventionMapping, getConventionMapping`

    - ### Methods inherited from class org.gradle.api.internal.AbstractTask

      `addValidator, compareTo, configure, deleteAllActions, dependsOn, dependsOnTaskDidWork, doFirst, doFirst, doLast, doLast, execute, executeWithoutThrowingTaskFailure, getActions, getAnt, getAsDynamicObject, getConvention, getDependsOn, getDescription, getDidWork, getEnabled, getExecuter, getExtensions, getGroup, getInputs, getLogger, getLogging, getName, getOnlyIf, getOutputs, getPath, getProject, getServices, getStandardOutputCapture, getState, getTaskDependencies, getTemporaryDir, getTemporaryDirFactory, getValidators, hasProperty, injectIntoNewInstance, isEnabled, leftShift, onlyIf, onlyIf, property, setActions, setDependsOn, setDescription, setDidWork, setEnabled, setExecuter, setGroup, setName, setOnlyIf, setOnlyIf, setProject, setProperty, toString`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### Groovydoc

          public Groovydoc()

  - ### Method Detail

    - #### generate

          protected void generate()

    - #### getDestinationDir

          @OutputDirectory
          public File getDestinationDir()

      Returns the directory to generate the documentation into.
      Returns:
        The directory to generate the documentation into

    - #### setDestinationDir

          public void setDestinationDir(File destinationDir)

      Sets the directory to generate the documentation into.

    - #### getGroovyClasspath

          @InputFiles
          public FileCollection getGroovyClasspath()

      Returns the classpath containing the Groovy library to be used.
      Returns:
        The classpath containing the Groovy library to be used

    - #### setGroovyClasspath

          public void setGroovyClasspath(FileCollection groovyClasspath)

      Sets the classpath containing the Groovy library to be used.

    - #### getClasspath

          @InputFiles
          public FileCollection getClasspath()

      Returns the classpath used to locate classes referenced by the documented sources.
      Returns:
        The classpath used to locate classes referenced by the documented sources

    - #### setClasspath

          public void setClasspath(FileCollection classpath)

      Sets the classpath used to locate classes referenced by the documented sources.

    - #### getAntGroovydoc

          public org.gradle.api.tasks.javadoc.AntGroovydoc getAntGroovydoc()

    - #### setAntGroovydoc

          public void setAntGroovydoc(org.gradle.api.tasks.javadoc.AntGroovydoc antGroovydoc)

    - #### isUse

          @Input
          public boolean isUse()

      Returns whether to create class and package usage pages.

    - #### setUse

          public void setUse(boolean use)

      Sets whether to create class and package usage pages.

    - #### getWindowTitle

          @Input
          @Optional
          public String getWindowTitle()

      Returns the browser window title for the documentation. Set to `null` when there is no window title.

    - #### setWindowTitle

          public void setWindowTitle(String windowTitle)

      Sets the browser window title for the documentation.
      Parameters:
        `windowTitle` - A text for the windows title

    - #### getDocTitle

          @Input
          @Optional
          public String getDocTitle()

      Returns the title for the package index(first) page. Set to `null` when there is no document title.

    - #### setDocTitle

          public void setDocTitle(String docTitle)

      Sets title for the package index(first) page (optional).
      Parameters:
        `docTitle` - the docTitle as html-code

    - #### getHeader

          @Input
          @Optional
          public String getHeader()

      Returns the html header for each page. Set to `null` when there is no header.

    - #### setHeader

          public void setHeader(String header)

      Sets header text for each page (optional).
      Parameters:
        `header` - the header as html-code

    - #### getFooter

          @Input
          @Optional
          public String getFooter()

      Returns the html footer for each page. Set to `null` when there is no footer.

    - #### setFooter

          public void setFooter(String footer)

      Sets footer text for each page (optional).
      Parameters:
        `footer` - the footer as html-code

    - #### getOverview

          public String getOverview()

      Returns a html file to be used for overview documentation. Set to `null` when there is no overview file.

    - #### setOverview

          public void setOverview(String overview)

      Sets a html file to be used for overview documentation (optional).

    - #### isIncludePrivate

          @Input
          public boolean isIncludePrivate()

      Returns whether to include all classes and members (i.e. including private ones).

    - #### setIncludePrivate

          public void setIncludePrivate(boolean includePrivate)

      Sets whether to include all classes and members (i.e. including private ones) if set to true.

    - #### getLinks

          @Input
          public Set<Groovydoc.Link> getLinks()

      Returns the links to groovydoc/javadoc output at the given URL.

    - #### setLinks

          public void setLinks(Set<Groovydoc.Link> links)

      Sets links to groovydoc/javadoc output at the given URL.
      Parameters:
        `links` - The links to set
      See Also:
        `link(String, String...)`

    - #### link

          public void link(String url,
                  String... packages)

      Add links to groovydoc/javadoc output at the given URL.
      Parameters:
        `url` - Base URL of external site
        `packages` - list of package prefixes