VariantsDescriptor

data class VariantsDescriptor(val element: String, val discriminator: String, val values: List<VariantDescriptor>)

An element of every record whose fields differ by variant: an EventStream record's body holds events whose payload fields depend on bodyType. A condition on one variant's field must be written inside an ELEMENT_MATCH on element together with the discriminator, so both apply to the same element.

Constructors

Link copied to clipboard
constructor(element: String, discriminator: String, values: List<VariantDescriptor>)

Properties

Link copied to clipboard

The element-relative field naming each element's variant, e.g. bodyType.

Link copied to clipboard

The element holding the variants, e.g. body.

Link copied to clipboard