I blogged recently about using public Collection
public class AddressCollection : Collection<Address> {
public AddressCollection() : base(new List<Address>()) { }
}
And I thought: why not to use generics to ensure that base class constructor is called? It works fine, I tested it:
Friday, May 30, 2008
A generic ListCollection<T> class
Comments by IntenseDebate
Posting anonymously.
A generic ListCollection<T> class
2008-05-30T13:24:00-04:00
Владимир
C#|