Interface Configuration


public interface Configuration
The Configuration interface describes the fully-qualified class name and the input parameters for an individual template invocation. A template can be invoke multiple times with different configurations.
Author:
Mirko Raner
  • Method Details

    • fullyQualifiedClassName

      String fullyQualifiedClassName()
      Returns:
      the fully qualified name of the class to be generated
    • parameters

      Map<String,​Object> parameters()
      Returns:
      additional parameters that need to be inserted into the code generation template
    • postProcessor

      default UnaryOperator<Writer> postProcessor()
      Returns:
      an operator that wraps the output writer into a filtering writer for post-processing
    • options

      default Options options()
      Retrieves additional configuration options that were provided as an annotation parameter or package annotation.
      Returns:
      the specified Options or a default Options object if not specified
    • isDefault

      default boolean isDefault​(Function<Options,​?> option)
      Checks if the specified option is set to the default value. This method will also return true if an option parameter was specified but happens to be identical to the default value (e.g., @Option(fileExtension=".java")).
      Parameters:
      option - the option to check (typically as a method reference)
      Returns:
      true if the option value is identical to the default value, false otherwise
    • isDefault

      default boolean isDefault​(Options options, Function<Options,​?> option)
    • defaults

      static Options defaults()