org.wildfly.swarm.microprofile.openapi.api

## Class OpenApiDocument

- java.lang.Object
- - org.wildfly.swarm.microprofile.openapi.api.OpenApiDocument

-     public class OpenApiDocument
      extends Object

  Holds the final OpenAPI document produced during the startup of the app.

  Note that the model must be initialized first!

  Author:
    Martin Kouba

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static OpenApiDocument` | `INSTANCE`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `archiveName(String archiveName)`
    `void` | `config(OpenApiConfig config)`
    `void` | `filter(OASFilter filter)`
    `OpenAPI` | `get()`
    `void` | `initialize()`
    `void` | `modelFromAnnotations(OpenAPI model)`
    `void` | `modelFromReader(OpenAPI model)`
    `void` | `modelFromStaticFile(OpenAPI model)`
    `void` | `reset()` Reset the holder.
    `void` | `set(OpenAPI model)` Set the final OpenAPI document.

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

      `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### INSTANCE

          public static final OpenApiDocument INSTANCE

  - ### Method Detail

    - #### get

          public OpenAPI get()

      Returns:
        the final OpenAPI document produced during the startup of the app
      Throws:
        `IllegalStateException` - If the final model is not initialized yet

    - #### set

          public void set(OpenAPI model)

      Set the final OpenAPI document. This method should only be used for testing.
      Parameters:
        `model` -

    - #### reset

          public void reset()

      Reset the holder.

    - #### config

          public void config(OpenApiConfig config)

    - #### modelFromAnnotations

          public void modelFromAnnotations(OpenAPI model)

    - #### modelFromReader

          public void modelFromReader(OpenAPI model)

    - #### modelFromStaticFile

          public void modelFromStaticFile(OpenAPI model)

    - #### filter

          public void filter(OASFilter filter)

    - #### archiveName

          public void archiveName(String archiveName)

    - #### initialize

          public void initialize()

Copyright © 2018 JBoss by Red Hat. All rights reserved.