pub struct UnionMeta<'a> { /* private fields */ }
Expand description
Union type metadata
Implementations§
source§impl<'a> UnionMeta<'a>
impl<'a> UnionMeta<'a>
sourcepub fn new(name: Cow<'a, str>, of_types: &[Type<'_>]) -> UnionMeta<'a>
pub fn new(name: Cow<'a, str>, of_types: &[Type<'_>]) -> UnionMeta<'a>
Build a new union type with the specified name and possible types
sourcepub fn description(self, description: &str) -> UnionMeta<'a>
pub fn description(self, description: &str) -> UnionMeta<'a>
Set the description of the type
If a description was provided prior to calling this method, it will be overwritten.