Collection interfaces
- From: "nooboy" <nospam@xxxxxxxxxx>
- Date: Wed, 19 Dec 2007 13:09:38 -0500
Confused about this concept. If I define some collection class and inherit
IList, I get an error if I don't implement the interface methods. This
makes sense.
But if I inherit from CollectionBase, I don't get this error, yet the
methods still don't seem to be implemented. For example, this code gives a
compile error.
class TestColl : IList
{
}
because, for one, it doesn't implement Add(...)
But this one does not give an error, even though the source for
CollectionBase shows that it does not implement Add(...) either.
class TestColl : CollectionBase, IList
{
}
What concept am I missing here?
.
- Follow-Ups:
- Re: Collection interfaces
- From: Liz
- Re: Collection interfaces
- From: Jon Skeet [C# MVP]
- Re: Collection interfaces
- Prev by Date: Re: Help with ISerializable help file paragraph.
- Next by Date: Re: Filtering DB Call based on local Data
- Previous by thread: Re: Transparent FOrm
- Next by thread: Re: Collection interfaces
- Index(es):
Relevant Pages
|