Interface FormatterProvider


  • public interface FormatterProvider
    Allows attaching a custom source formatter.

    Note: This interface is meant to be consumed by Roaster only.

    Author:
    George Gastaldi
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      java.lang.String format​(java.lang.String source)
      Format the provided source code.
      java.lang.String format​(java.util.Properties properties, java.lang.String source)
      Format the source code, given the required Properties.
    • Method Detail

      • format

        java.lang.String format​(java.lang.String source)
        Format the provided source code.
        Parameters:
        source - a Java source file content
        Returns:
        the formatted version of the source
      • format

        java.lang.String format​(java.util.Properties properties,
                                java.lang.String source)
        Format the source code, given the required Properties. The properties are meant to interpreted implementation specific.
        Parameters:
        properties - implementation specific formatting options
        source - a Java source file content
        Returns:
        the formatted version of the source