Immutable Collections

I just saw an interesting post that talks about a general pattern of immutable reference types. Good read. I highly recommend it! At the end of the post the author suggests that we add “value object” generic collection to the BCL. It’s an interesting suggestion, but unfortunately not as easy as it may seem. The…

4

Why Do We Have EventArgs Class?

There is an interesting thread on MSDN newsgroups (see “event arguments” thread) about the design of our eventing APIs. The question is why do we even have EventArgs class (which is empty)? Should we just allow the second parameter to the event handlers to be an arbitrary type? We created EventArgs to make it easier…

9

Activator.CreateInstance<T> – System.Type vs. Generic Method

Daniel Moth asked, in his post, how to choose between a generic type parameter vs. a formal parameter of typed as System.Type. For example, the following two members seem equivalent. public class Activator {    public static object CreateInstance(Type instanceType);    // or?    public static T CreateInstance<T>(); } The generic method seems slightly better, as it returns…

9

Fix to TxRef

The Framework Design Guidelines book comes with a tool called TxRef. The tool was built with Beta 2 version of the Framework 2.0 and will not compile on the RTM version. Kathy just posted a fix to the problem. See http://blogs.msdn.com/kathykam/archive/2005/11/16/493685.aspx.

0

FDG book readership beyond our wildest dreams

The Framework Design Guidelines book is being read by readers we never thought would be interested in API design. Richard has captured a photo showing one of the readers being simply glued to the Type Design chapter.

0