I would like to be able to do something like this :
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace Test
{
Although List implements IEnumerable that's not the way interfaces work. The interface specifies exactly which types need to be exposed for properties. If you created a generic interface like
public interface IFoo where T : IEnumerable
{
T integers { get; set; }
}
You could then use IFoo
to implement it in the way you expect.>