avro_union: avro_union

Description Usage Arguments Examples

Description

Constructs a list of lists Avro schema for the tagged union type.

Usage

1

Arguments

...

schemas for each of the possible sub-types

Examples

1
2
avro_union(avro_null, avro_int)         # a way to make a nullable int
avro_union(avro_double, avro_string)    # any set of types can be unioned

Example output

[[1]]
[1] "null"

[[2]]
[1] "int"

[[1]]
[1] "double"

[[2]]
[1] "string"

aurelius documentation built on May 2, 2019, 3:43 a.m.