T UnionFactory<{T}> = T Function(int index, Object data)
typedef UnionFactory<T> = T Function(int index, Object data);