我想扩展一个Element是泛型类型的嵌套类的Array: class GenericType<T: ExpressibleByInt> { }GenericType.NestedClass { // Fails: Reference to generic type 'GenericType' requires arguments in <...>.} 当泛型</e
为了方便起见,我想为RxDart类创建一些扩展类。但我找不到一种方法来对泛型做一些基本的事情,例如,我需要将泛型类型限制为几个类型。下面是我如何在C#中实现它 MyGenericType<T> where T : bool, int { ... } 因此将T限制为bool和int类型。我如何在dart中做同样的事情呢?这些文档仅显示具有如下单一类型限制的示例: class MyGeneric<T extends So