プロパティを持つクラスがありますIEnumerable<T>
。List<T>
new を作成してそのプロパティを割り当てるジェネリック メソッドを作成するにはどうすればよいですか?
IList list = property.PropertyType.GetGenericTypeDefinition()
.MakeGenericType(property.PropertyType.GetGenericArguments())
.GetConstructor(Type.EmptyTypes);
T
タイプがどこにあるのかわかりません