public JSType createUnionType ( JSType ... variants ) { UnionTypeBuilder builder = UnionTypeBuilder . create ( this ) ; for ( JSType type : variants ) { builder . addAlternate ( type ) ; } return builder . build ( ) ; }
Creates a union type whose variants are the arguments .