Class FileWriterPostProcessor

java.lang.Object
com.github.chhorz.openapi.common.spi.FileWriterPostProcessor
All Implemented Interfaces:
OpenAPIPostProcessor

public class FileWriterPostProcessor extends Object implements OpenAPIPostProcessor
A custom OpenAPIPostProcessor that writes the OpenAPI domain object to a local file.
Author:
chhorz
  • Method Details

    • execute

      public void execute(OpenAPI openApi)
      This method must be overridden for the actual post-processing call. Otherwise, the default implementation will throw an UnsupportedOperationException.
      Specified by:
      execute in interface OpenAPIPostProcessor
      Parameters:
      openApi - the parsed OpenAPI for which the post-processing should be done
    • getPostProcessorOrder

      public int getPostProcessorOrder()
      Returns the value for the order in which the post processor should be executed. Possible values are between Integer.MIN_VALUE and Integer.MAX_VALUE. The processors will be executed starting with the highest value.
      Specified by:
      getPostProcessorOrder in interface OpenAPIPostProcessor
      Returns:
      the order in which the post processor should be executed
    • getPostProcessorType

      public List<PostProcessorType> getPostProcessorType()
      Defines the input types of the current post processor. The post processor is executed at a different step of the generation process depending on the input type.
      Specified by:
      getPostProcessorType in interface OpenAPIPostProcessor
      Returns:
      a list of input types for the post processor