io.vertx.rxjava3.openapi.contract

## Class OpenAPIContract

- java.lang.Object
- - io.vertx.rxjava3.openapi.contract.OpenAPIContract

- All Implemented Interfaces:
    io.vertx.lang.rx.RxDelegate

      public class OpenAPIContract
      extends Object
      implements io.vertx.lang.rx.RxDelegate

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static io.vertx.lang.rx.TypeArg<OpenAPIContract>` | `__TYPE_ARG`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `OpenAPIContract(Object delegate)`
    `OpenAPIContract(OpenAPIContract delegate)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `equals(Object o)`
    `Operation` | `findOperation(String urlPath, HttpMethod method)` Finds the related `Operation` object based on the passed url path and method.
    `Path` | `findPath(String urlPath)` Finds the related `Path` object based on the passed url path.
    `static Single<OpenAPIContract>` | `from(Vertx vertx, JsonObject unresolvedContract)` Resolves / dereferences the passed contract and creates an `OpenAPIContract` instance.
    `static Single<OpenAPIContract>` | `from(Vertx vertx, JsonObject unresolvedContract, Map<String,JsonObject> additionalContractFiles)` Resolves / dereferences the passed contract and creates an `OpenAPIContract` instance.
    `static Single<OpenAPIContract>` | `from(Vertx vertx, String unresolvedContractPath)` Resolves / dereferences the passed contract and creates an `OpenAPIContract` instance.
    `static Single<OpenAPIContract>` | `from(Vertx vertx, String unresolvedContractPath, Map<String,String> additionalContractFiles)` Resolves / dereferences the passed contract and creates an `OpenAPIContract` instance.
    `OpenAPIContract` | `getDelegate()`
    `List<Path>` | `getPaths()`
    `JsonObject` | `getRawContract()`
    `SchemaRepository` | `getSchemaRepository()`
    `List<SecurityRequirement>` | `getSecurityRequirements()` Returns the applicable list of global security requirements (scopes) or empty list.
    `List<Server>` | `getServers()`
    `OpenAPIVersion` | `getVersion()`
    `int` | `hashCode()`
    `static OpenAPIContract` | `newInstance(OpenAPIContract arg)`
    `Operation` | `operation(String operationId)` Access to an operation defined in the contract with `operationId`.
    `List<Operation>` | `operations()`
    `static Single<OpenAPIContract>` | `rxFrom(Vertx vertx, JsonObject unresolvedContract)` Resolves / dereferences the passed contract and creates an `OpenAPIContract` instance.
    `static Single<OpenAPIContract>` | `rxFrom(Vertx vertx, JsonObject unresolvedContract, Map<String,JsonObject> additionalContractFiles)` Resolves / dereferences the passed contract and creates an `OpenAPIContract` instance.
    `static Single<OpenAPIContract>` | `rxFrom(Vertx vertx, String unresolvedContractPath)` Resolves / dereferences the passed contract and creates an `OpenAPIContract` instance.
    `static Single<OpenAPIContract>` | `rxFrom(Vertx vertx, String unresolvedContractPath, Map<String,String> additionalContractFiles)` Resolves / dereferences the passed contract and creates an `OpenAPIContract` instance.
    `SecurityScheme` | `securityScheme(String name)` Gets the related `SecurityScheme` object based on the passed name.
    `String` | `toString()`

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

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### __TYPE_ARG

          public static final io.vertx.lang.rx.TypeArg<OpenAPIContract> __TYPE_ARG

  - ### Constructor Detail

    - #### OpenAPIContract

          public OpenAPIContract(OpenAPIContract delegate)

    - #### OpenAPIContract

          public OpenAPIContract(Object delegate)

  - ### Method Detail

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

    - #### equals

          public boolean equals(Object o)

      Overrides:
        `equals` in class `Object`

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `Object`

    - #### getDelegate

          public OpenAPIContract getDelegate()

      Specified by:
        `getDelegate` in interface `io.vertx.lang.rx.RxDelegate`

    - #### from

          public static Single<OpenAPIContract> from(Vertx vertx,
                                                     String unresolvedContractPath)

      Resolves / dereferences the passed contract and creates an `OpenAPIContract` instance.
      Parameters:
        `vertx` - The related Vert.x instance.
        `unresolvedContractPath` - The path to the unresolved contract.
      Returns:
        A succeeded holding an `OpenAPIContract` instance, otherwise a failed .

    - #### rxFrom

          public static Single<OpenAPIContract> rxFrom(Vertx vertx,
                                                       String unresolvedContractPath)

      Resolves / dereferences the passed contract and creates an `OpenAPIContract` instance.
      Parameters:
        `vertx` - The related Vert.x instance.
        `unresolvedContractPath` - The path to the unresolved contract.
      Returns:
        A succeeded holding an `OpenAPIContract` instance, otherwise a failed .

    - #### from

          public static Single<OpenAPIContract> from(Vertx vertx,
                                                     JsonObject unresolvedContract)

      Resolves / dereferences the passed contract and creates an `OpenAPIContract` instance.
      Parameters:
        `vertx` - The related Vert.x instance.
        `unresolvedContract` - The unresolved contract.
      Returns:
        A succeeded holding an `OpenAPIContract` instance, otherwise a failed .

    - #### rxFrom

          public static Single<OpenAPIContract> rxFrom(Vertx vertx,
                                                       JsonObject unresolvedContract)

      Resolves / dereferences the passed contract and creates an `OpenAPIContract` instance.
      Parameters:
        `vertx` - The related Vert.x instance.
        `unresolvedContract` - The unresolved contract.
      Returns:
        A succeeded holding an `OpenAPIContract` instance, otherwise a failed .

    - #### from

          public static Single<OpenAPIContract> from(Vertx vertx,
                                                     String unresolvedContractPath,
                                                     Map<String,String> additionalContractFiles)

      Resolves / dereferences the passed contract and creates an `OpenAPIContract` instance.

      This method can be used in case that the contract is split into several files. These files can be passed in a Map that has the reference as key and the path to the file as value.

      Parameters:
        `vertx` - The related Vert.x instance.
        `unresolvedContractPath` - The path to the unresolved contract.
        `additionalContractFiles` - The additional contract files
      Returns:
        A succeeded holding an `OpenAPIContract` instance, otherwise a failed .

    - #### rxFrom

          public static Single<OpenAPIContract> rxFrom(Vertx vertx,
                                                       String unresolvedContractPath,
                                                       Map<String,String> additionalContractFiles)

      Resolves / dereferences the passed contract and creates an `OpenAPIContract` instance.

      This method can be used in case that the contract is split into several files. These files can be passed in a Map that has the reference as key and the path to the file as value.

      Parameters:
        `vertx` - The related Vert.x instance.
        `unresolvedContractPath` - The path to the unresolved contract.
        `additionalContractFiles` - The additional contract files
      Returns:
        A succeeded holding an `OpenAPIContract` instance, otherwise a failed .

    - #### from

          public static Single<OpenAPIContract> from(Vertx vertx,
                                                     JsonObject unresolvedContract,
                                                     Map<String,JsonObject> additionalContractFiles)

      Resolves / dereferences the passed contract and creates an `OpenAPIContract` instance.

      This method can be used in case that the contract is split into several files. These files can be passed in a Map that has the reference as key and the path to the file as value.

      Parameters:
        `vertx` - The related Vert.x instance.
        `unresolvedContract` - The unresolved contract.
        `additionalContractFiles` - The additional contract files
      Returns:
        A succeeded holding an `OpenAPIContract` instance, otherwise a failed .

    - #### rxFrom

          public static Single<OpenAPIContract> rxFrom(Vertx vertx,
                                                       JsonObject unresolvedContract,
                                                       Map<String,JsonObject> additionalContractFiles)

      Resolves / dereferences the passed contract and creates an `OpenAPIContract` instance.

      This method can be used in case that the contract is split into several files. These files can be passed in a Map that has the reference as key and the path to the file as value.

      Parameters:
        `vertx` - The related Vert.x instance.
        `unresolvedContract` - The unresolved contract.
        `additionalContractFiles` - The additional contract files
      Returns:
        A succeeded holding an `OpenAPIContract` instance, otherwise a failed .

    - #### operation

          public Operation operation(String operationId)

      Access to an operation defined in the contract with `operationId`.
      Parameters:
        `operationId` - the id of the operation.
      Returns:
        the requested operation.

    - #### operations

          public List<Operation> operations()

      Returns:
        all operations defined in the contract.

    - #### getPaths

          public List<Path> getPaths()

      Returns:
        all `Paths` defined in the OpenAPI contract.

    - #### getRawContract

          public JsonObject getRawContract()

      Returns:
        the resolved OpenAPI contract as .

    - #### getVersion

          public OpenAPIVersion getVersion()

      Returns:
        the OpenAPI version of the contract.

    - #### getSchemaRepository

          public SchemaRepository getSchemaRepository()

      Returns:
        the to validate against.

    - #### getServers

          public List<Server> getServers()

      Returns:
        the servers of the contract.

    - #### findPath

          public Path findPath(String urlPath)

      Finds the related `Path` object based on the passed url path.
      Parameters:
        `urlPath` - The path of the request.
      Returns:
        the found `Path` object, or null if the passed path doesn't match any `Path` object.

    - #### findOperation

          public Operation findOperation(String urlPath,
                                         HttpMethod method)

      Finds the related `Operation` object based on the passed url path and method.
      Parameters:
        `urlPath` - The path of the request.
        `method` - The method of the request.
      Returns:
        the found `Operation` object, or null if the passed path and method doesn't match any `Operation` object.

    - #### getSecurityRequirements

          public List<SecurityRequirement> getSecurityRequirements()

      Returns the applicable list of global security requirements (scopes) or empty list.
      Returns:
        The related security requirement.

    - #### securityScheme

          public SecurityScheme securityScheme(String name)

      Gets the related `SecurityScheme` object based on the passed name.
      Parameters:
        `name` - The name of the security scheme.
      Returns:
        the found `SecurityScheme` object, or null if the passed path and method doesn't match any `Operation` object.

    - #### newInstance

          public static OpenAPIContract newInstance(OpenAPIContract arg)

Copyright © 2025 Eclipse. All rights reserved.