The Artima Developer Community
Sponsored Link

.NET Buzz Forum
.NET 2.0 - What's the difference between System.Collections.Generic.Collection and...

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
Scott Hanselman

Posts: 1031
Nickname: glucopilot
Registered: Aug, 2003

Scott Hanselman is the Chief Architect at Corillian Corporation and the Microsoft RD for Oregon.
.NET 2.0 - What's the difference between System.Collections.Generic.Collection and... Posted: Aug 1, 2004 1:19 AM
Reply to this message Reply

This post originated from an RSS feed registered with .NET Buzz by Scott Hanselman.
Original Post: .NET 2.0 - What's the difference between System.Collections.Generic.Collection and...
Feed Title: Scott Hanselman's ComputerZen.com
Feed URL: http://radio-weblogs.com/0106747/rss.xml
Feed Description: Scott Hanselman's ComputerZen.com is a .NET/WebServices/XML Weblog. I offer details of obscurities (internals of ASP.NET, WebServices, XML, etc) and best practices from real world scenarios.
Latest .NET Buzz Posts
Latest .NET Buzz Posts by Scott Hanselman
Latest Posts From Scott Hanselman's ComputerZen.com

Advertisement

Anyone want to tell me what's the difference between System.Collections.Generic.Collection and System.Collections.Generic.List?

  • Collection<T> looks like a list, and it even has a List<T> internally.  EVERY single method delegates to the internal List<T>.  It includes a protected property that exposes the List<T>.
  • List<T> uses an array (T[]) internally and includes all this great anonymous delegate/predicate stuff like Find() and FindAll().
  • They both implement IList and ICollection.

Another weird one, Microsoft.VisualBasic still has the oddball Collection class that implements ICollection and IList.  Presumably this type exists only to help VB6 developers make the transition?

Read: .NET 2.0 - What's the difference between System.Collections.Generic.Collection and...

Topic: Python for .Net Previous Topic   Next Topic Topic: Indigo programming model goodness

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use