resolveSchemaRef

fun resolveSchemaRef(schema: Schema<*>?, openAPI: OpenAPI?): Schema<*>?

Null-tolerant variant of tryGetSchemaFromRef for standard #/components/schemas/ resolution. Returns null for a null schema, and the schema unchanged when openAPI is null or the reference cannot be resolved.

Return

dereferenced schema, the original input, or null when schema is null

Parameters

schema

schema that may contain a $ref, or null

openAPI

OpenAPI document providing component definitions, or null