anyOf

Creates an anyOf property definition.

Validates that the value matches one or more of the provided schemas. Unlike oneOf, the value can match multiple schemas simultaneously.

Example

property("value") {
anyOf {
description = "A value that can be a string or number"
string { minLength = 1 }
number { minimum = 0.0 }
}
}

Return

A configured AnyOfPropertyDefinition

Parameters

block

Configuration for the anyOf property

See also