Interface OpenAPI

    • Method Detail

      • getOpenapi

        java.lang.String getOpenapi​()
        Returns the openapi property from an OpenAPI instance.
        Returns:
        the semantic version number of the OpenAPI Specification version that the OpenAPI document uses
      • setOpenapi

        void setOpenapi​(java.lang.String openapi)
        Sets this OpenAPI instance's openapi property to the given string.
        Parameters:
        openapi - the semantic version number of the OpenAPI Specification version that the OpenAPI document uses
      • openapi

        OpenAPI openapi​(java.lang.String openapi)
        Sets this OpenAPI instance's openapi property to the given string.
        Parameters:
        openapi - the semantic version number of the OpenAPI Specification version that the OpenAPI document uses
        Returns:
        the current OpenAPI object
      • getInfo

        Info getInfo​()
        Returns the info property from an OpenAPI instance.
        Returns:
        metadata about the API
      • setInfo

        void setInfo​(Info info)
        Sets this OpenAPI instance's info property to the given object.
        Parameters:
        info - metadata about the API
      • info

        OpenAPI info​(Info info)
        Sets this OpenAPI instance's info property to the given object.
        Parameters:
        info - metadata about the API
        Returns:
        the current OpenAPI object
      • getExternalDocs

        ExternalDocumentation getExternalDocs​()
        Returns the externalDocs property from an OpenAPI instance.
        Returns:
        additional external documentation
      • setExternalDocs

        void setExternalDocs​(ExternalDocumentation externalDocs)
        Sets this OpenAPI instance's externalDocs property to the given object.
        Parameters:
        externalDocs - additional external documentation.
      • externalDocs

        OpenAPI externalDocs​(ExternalDocumentation externalDocs)
        Sets this OpenAPI instance's externalDocs property to the given object.
        Parameters:
        externalDocs - additional external documentation
        Returns:
        the current OpenAPI object
      • getServers

        java.util.List<Server> getServers​()
        Returns the Servers defined in the API
        Returns:
        Server objects which provide connectivity information to target servers
      • setServers

        void setServers​(java.util.List<Server> servers)
        Sets this OpenAPI instance's servers property to the given servers.
        Parameters:
        servers - Server objects which provide connectivity information to target servers
      • servers

        OpenAPI servers​(java.util.List<Server> servers)
        Sets this OpenAPI instance's servers property to the given servers.
        Parameters:
        servers - Server objects which provide connectivity information to target servers
        Returns:
        the current OpenAPI object
      • addServer

        OpenAPI addServer​(Server server)
        Adds the given server to this OpenAPI instance's list of servers.
        Parameters:
        server - Server object which provides connectivity information to a target server
        Returns:
        the current OpenAPI object
      • getSecurity

        java.util.List<SecurityRequirement> getSecurity​()
        Returns the security property from an OpenAPI instance.
        Returns:
        which security mechanisms can be used across the API
      • setSecurity

        void setSecurity​(java.util.List<SecurityRequirement> security)
        Sets this OpenAPI instance's security property to the given list.
        Parameters:
        security - which security mechanisms can be used across the API
      • security

        OpenAPI security​(java.util.List<SecurityRequirement> security)
        Sets this OpenAPI instance's security property to the given list.
        Parameters:
        security - which security mechanisms can be used across the API
        Returns:
        the current OpenAPI object
      • addSecurityRequirement

        OpenAPI addSecurityRequirement​(SecurityRequirement securityRequirement)
        Adds the given security requirement to this OpenAPI instance's list of security requirements.
        Parameters:
        securityRequirement - security mechanism which can be used across the API
        Returns:
        the current OpenAPI object
      • getTags

        java.util.List<Tag> getTags​()
        Returns the tags property from an OpenAPI instance.
        Returns:
        tags used by the specification
      • setTags

        void setTags​(java.util.List<Tag> tags)
        Sets this OpenAPI instance's tags property to the given Tags.
        Parameters:
        tags - tags used by the specification with additional metadata
      • tags

        OpenAPI tags​(java.util.List<Tag> tags)
        Sets this OpenAPI instance's tags property to the given tags.
        Parameters:
        tags - tags used by the specification with additional metadata
        Returns:
        the current OpenAPI object
      • addTag

        OpenAPI addTag​(Tag tag)
        Adds the given tag to this OpenAPI instance's list of tags.
        Parameters:
        tag - a tag used by the specification with additional metadata
        Returns:
        the current OpenAPI object
      • getPaths

        Paths getPaths​()
        Returns the paths property from an OpenAPI instance.
        Returns:
        the available paths and operations for the API
      • setPaths

        void setPaths​(Paths paths)
        Sets this OpenAPI instance's paths property to the given paths.
        Parameters:
        paths - the available paths and operations for the API
      • paths

        OpenAPI paths​(Paths paths)
        Sets this OpenAPI instance's paths property to the given paths.
        Parameters:
        paths - the available paths and operations for the API
        Returns:
        the current OpenAPI object
      • path

        OpenAPI path​(java.lang.String name,
                     PathItem path)
        Adds the given path item to this OpenAPI instance's list of paths
        Parameters:
        name - a path name in the format valid for a Paths object
        path - the path item added to the list of paths
        Returns:
        the current OpenAPI object
      • getComponents

        Components getComponents​()
        Returns the components property from an OpenAPI instance.
        Returns:
        schemas used in the specification
      • setComponents

        void setComponents​(Components components)
        Sets this OpenAPI instance's components property to the given components.
        Parameters:
        components - a set of reusable objects used in the API specification
      • components

        OpenAPI components​(Components components)
        Sets this OpenAPI instance's components property to the given components.
        Parameters:
        components - a set of reusable objects used in the API specification
        Returns:
        the current OpenAPI object