Interface Configuration

All Known Implementing Classes:
DocletConfig

public interface Configuration
Configuration that influences how UML should be rendered.
Author:
Sjoerd Talsma
  • Method Details

    • plantumlServerUrl

      Optional<String> plantumlServerUrl()
      The base URL of the PlantUML server to generate diagrams with.

      Please note that it is not recommended to use the public, central PlantUML server at https://www.plantuml.com/plantuml. Although not strictly forbidden by the author of PlantUML, using the central server to generate your javadoc diagrams is causing additional load on the central server and is a lot slower than running your own local server.

      Using docker to run a local PlantUML server can be a simple as:

      
       docker run -d -p 8080:8080 plantuml/plantuml-server:latest
       
      After that, you can run the UMLDoclet with plantumlServerUrl = "http://localhost:8080/"
      Returns:
      The base URL of the PlantUML online server to use.
    • delegateDocletName

      @Deprecated(since="2.0.21", forRemoval=true) Optional<String> delegateDocletName()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Delegation to another Doclet does not work at te moment unfortunately.
      The name of the doclet to delegate main documentation to or Optional.empty() if no delegation is wanted.
      Returns:
      The name of the doclet to delegate main documentation to or Optional.empty() if no delegation is wanted.
    • logger

      Logger logger()
      Configured logger for this doclet.

      This is a simple, custom logging implementation so we do not have to introduce an external dependency.

      Returns:
      The logger for this application
    • indentation

      Indentation indentation()
      The indentation configuration for generated PlantUML source files.
      Returns:
      The indentation configuration.
    • destinationDirectory

      String destinationDirectory()
      Destination directory for JavaDoc and UML diagrams, or the empty string "" to use the current directory.
      Returns:
      Destination directory for JavaDoc and UML diagrams, or the empty string "" for the current directory.
    • renderPumlFile

      boolean renderPumlFile()
      Whether PlantUML source files are generated.

      PlantUML source files have the .puml filename extension.

      Returns:
      true if PlantUML source files must be generated, otherwise false.
    • images

      ImageConfig images()
      Configuration for generated images.
      Returns:
      Configuration for generated images.
    • fields

      FieldConfig fields()
      Configuration for generated UML fields.
      Returns:
      UML field configuration.
    • methods

      MethodConfig methods()
      Configuration for generated UML methods.
      Returns:
      UML method configuration.
    • excludedTypeReferences

      List<String> excludedTypeReferences()
      Names of types that are excluded as reference.

      Types can be any java type, such as classes and interfaces.

      Names should match exactly with the fully quallified type names.

      Returns:
      The types (classes, interfaces) that are excluded as references.
    • excludedPackageDependencies

      List<String> excludedPackageDependencies()
      Names of packages that are excluded as package dependencies.

      The specified package names and any subpackages will be excluded from package dependency diagrams.

      Returns:
      The packages (including subpackages) excluded from the package dependencies.
    • failOnCyclicPackageDependencies

      boolean failOnCyclicPackageDependencies()
      Whether a detected package dependency cycle must result in an error (instead of a warning).
      Returns:
      true if a detected package dependency cycle must be considered as an error, or false if it should be reported as merely a warning.
    • resolveExternalLinkToType

      Optional<URI> resolveExternalLinkToType(String packageName, String type)
      Resolves an external link to the specified type.
      Parameters:
      packageName - The package of the type.
      type - The type name within the package.
      Returns:
      The external link, if resolved.
    • customPlantumlDirectives

      List<String> customPlantumlDirectives()
      Custom directives to include in rendered PlantUML diagram sources.

      Custom directives are rendered as-is at the top of each PlantUML diagram. For example, to use jdot for rendering, use the "!pragma graphviz_dot jdot" custom directive.

      Returns:
      Any custom PlantUML directives.
    • umlCharset

      Charset umlCharset()
      The UML character set can be explicitly configured with the "-umlEncoding" option.

      If this is not explicitly set, the htmlCharset() will also be used for the PlantUML source files.

      This encoding is irrelevant if renderPumlFile() is set to false.
      Also, diagram files are rendered as binary files, so no explicit encoding is used for them.

      Returns:
      The charset to use for PlantUML source files (".puml" files).
    • htmlCharset

      Charset htmlCharset()
      The HTML character set is determined the same way the Standard doclet uses, as we delegate the initial rendering to it:
      1. use the "-docencoding" if set,
      2. otherwise the source encoding ("-encoding")
      3. finally, if no encodings are specified at all, the default platform encoding is used as implicit fallback.
      Returns:
      The charset used for Javadoc HTML files.