Sign in
Krzysztof Cwalina
Designing Reusable Frameworks
Translate This Page
Translate this page
Powered by
Microsoft® Translator
Options
About
Email Blog Author
RSS for posts
Atom
RSS for comments
OK
Search
Tags
Design Guidelines
General API Design
General Programming
MEF
PLP
System.Collections
System.Diagnostics Tracing
Archive
Archives
September 2011
(1)
June 2011
(1)
June 2009
(1)
March 2009
(1)
January 2009
(1)
October 2008
(2)
September 2008
(1)
August 2008
(1)
July 2008
(3)
June 2008
(2)
April 2008
(4)
March 2008
(2)
January 2008
(2)
October 2007
(3)
July 2007
(3)
June 2007
(2)
May 2007
(1)
April 2007
(2)
March 2007
(1)
February 2007
(1)
January 2007
(2)
October 2006
(1)
August 2006
(2)
July 2006
(3)
June 2006
(1)
May 2006
(1)
March 2006
(3)
February 2006
(3)
December 2005
(3)
November 2005
(5)
October 2005
(1)
September 2005
(9)
August 2005
(2)
June 2005
(3)
May 2005
(4)
April 2005
(1)
March 2005
(2)
January 2005
(1)
November 2004
(4)
October 2004
(3)
September 2004
(2)
August 2004
(1)
June 2004
(2)
May 2004
(2)
April 2004
(1)
March 2004
(3)
Posts
Subscribe via RSS
Sort by:
Most Recent
|
Most Views
|
Most Comments
Excerpt View
|
Full Post View
Krzysztof Cwalina
Disposable Collection
Posted
over 7 years ago
by
Krzysztof Cwalina
12
Comments
Somebody asked me today, if we have a collection that is disposable and calls dispose on all its items when the collections.Dispose method is called. You can implement such collection by inheriting from List<T> and adding Dispose logic. If you add...
Krzysztof Cwalina
Krzysztof’s Laws of API Design
Posted
over 8 years ago
by
Krzysztof Cwalina
10
Comments
I always thought about writing down the laws of APIs design. By "laws", I mean principles that don’t seem to change based on the particular scenario at hand, whether the API is low of high level, etc. Here is my first try. I would appreciate any comments....
Krzysztof Cwalina
I don’t like the “Base” suffix
Posted
over 8 years ago
by
Krzysztof Cwalina
6
Comments
Today, I was reviewing a set of recommendation for naming types intended to be inherited from. The author suggested using the “Base” suffix for such types. I personally don’t like to do this. Here are the reasons: First, what do you call base of a...
Krzysztof Cwalina
Channel 9 video showing a real usability study
Posted
over 8 years ago
by
Krzysztof Cwalina
1
Comments
Channel 9 just posted a video in which our API usability engineers talk about one of the studies they conducted recently, but what’s even more interesting, in part two of the story, they show a clip from an actual study where a participant writes a workflow...
Krzysztof Cwalina
Immutable Collections
Posted
over 8 years ago
by
Krzysztof Cwalina
4
Comments
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...
Krzysztof Cwalina
Why Do We Have EventArgs Class?
Posted
over 8 years ago
by
Krzysztof Cwalina
9
Comments
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...
Krzysztof Cwalina
Activator.CreateInstance<T> - System.Type vs. Generic Method
Posted
over 8 years ago
by
Krzysztof Cwalina
9
Comments
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...
Krzysztof Cwalina
Fix to TxRef
Posted
over 8 years ago
by
Krzysztof Cwalina
0
Comments
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...
Krzysztof Cwalina
FDG book readership beyond our wildest dreams
Posted
over 8 years ago
by
Krzysztof Cwalina
0
Comments
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.
Krzysztof Cwalina
SYS-CON TV Interview
Posted
over 8 years ago
by
Krzysztof Cwalina
3
Comments
I did an interview for SYS-CON TV. I talked about the Framework Design Guidelines book and other API related things. The interview can be viewed at http://www.sys-con.tv/read/137736.htm .
Krzysztof Cwalina
Ship Party!
Posted
over 8 years ago
by
Krzysztof Cwalina
2
Comments
Online publishers have started shipping the Framework Design Guidelines book. Before, it was pre-order-only. I think Brad and I deserve a ship party :-) BTW, “ship party” is the term we use at Microsoft for a party we organize for ourselves after releasing...
Krzysztof Cwalina
Free Chapter from the Framework Design Guidelines Book
Posted
over 8 years ago
by
Krzysztof Cwalina
2
Comments
Addison Wesley, the publisher of the Framework Design Guidelines book has posted a freely downloadable chapter . The chapter talks about type design.
Krzysztof Cwalina
Why we don’t recommend using List<T> in public APIs
Posted
over 8 years ago
by
Krzysztof Cwalina
30
Comments
We don’t recommend using List<T> in public APIs for two reasons. List<T> is not designed to be extended. i.e. you cannot override any members. This for example means that an object returning List<T> from a property won’t be able...
Krzysztof Cwalina
System.Collections vs. System.Collection.Generic and System.Collections.ObjectModel
Posted
over 8 years ago
by
Krzysztof Cwalina
24
Comments
Many people ask how the new.NET Framework 2.0 generic collections relate to the non-generic collections we shipped before. So, here you go. The most important types are in bold font. List<T> is basically a better ArrayList. It is optimized for...
Krzysztof Cwalina
Workflow Application Model
Posted
over 8 years ago
by
Krzysztof Cwalina
0
Comments
I just found a very interesting blog written by Dave Green (an architect of the Windows Workflow Foundation). One of the posts explains the main motivations for creating a workflow framework. In general I am a big fan of the work this team has done...
Krzysztof Cwalina
Value Type EventArgs
Posted
over 8 years ago
by
Krzysztof Cwalina
6
Comments
I just wanted to blog about some interesting API design discussion we had recently . We discussed whether to relax the event design guidelines to allow value type "event args." This would make raising some events cheaper. public struct SomethingHappenedEventArgs...
Krzysztof Cwalina
Tracing APIs in .NET Framework 2.0
Posted
over 8 years ago
by
Krzysztof Cwalina
1
Comments
I found a very encouraging post about the new tracing APIs that we added to .NET Framework 2.0. Kathleen Dollard wrote : “ Sometimes Microsoft absolutely amazes me. I know .NET is big, and I know that the 2.0 release is rather overwhelming even to Softies...
Krzysztof Cwalina
PDC 2005 Summary
Posted
over 8 years ago
by
Krzysztof Cwalina
1
Comments
I just wanted to post something to summarize the PDC 2005. PDC started for me on Monday. Brad and I were presenting at a precon on Designing Reusable APIs. 6 hours total. The slides can be downloaded here . We were tweaking slides till midnight...
Krzysztof Cwalina
The Role of the API designer: Design what the user needs
Posted
over 8 years ago
by
Krzysztof Cwalina
0
Comments
Since I have been preparing for the PDC and finishing the book , I neglected blogging. All ideas for posts were just ending up in the “to do” folder (yes, Outlook drives my life J). Now, I will try to catch up. I was reading Paul Grahm’s essay on Design...
Krzysztof Cwalina
Framework Design Guidelines book went to print
Posted
over 8 years ago
by
Krzysztof Cwalina
5
Comments
I have just heard from the publisher that the Framework Design Guidelines book just went to print. To celebrate and to thank for the contributions, I thought I would blog the list of people who provided annotations for the book: Brad Abrams , Mark...
Krzysztof Cwalina
List<T> vs. ArrayList Performance
Posted
over 8 years ago
by
Krzysztof Cwalina
0
Comments
Rico just posted a new performance quiz where he compares performance of List<T> and ArrayList in some simple scenarios. List<T> is my Whidbey baby, so of course I had to answer that List<T> is faster :-)
Krzysztof Cwalina
Factories in APIs
Posted
over 8 years ago
by
Krzysztof Cwalina
0
Comments
Steven Clarke has an excellent post about using factories in APIs . The post explains why some developers find factories difficult to use.
Krzysztof Cwalina
Book Progress and Progrssive APIs
Posted
over 8 years ago
by
Krzysztof Cwalina
1
Comments
After posting about the Scenario Driven Design and the Design Guidelines book we are working on, I got several questions on that is "progressive API". Coincidentally I just submitted the final manuscript for a chapter that has a section on progressive APIs, so here is the related excerpt:...
Krzysztof Cwalina
PowerCollections Beta Avaliable
Posted
over 8 years ago
by
Krzysztof Cwalina
1
Comments
The beta release of the PowerCollections library has been posted today. See http://wintellect.com/WEBLOGS/pgolde/archive/2005/06/03/1304.aspx .
Krzysztof Cwalina
Should Exceptions Carry Error Code Information
Posted
over 8 years ago
by
Krzysztof Cwalina
5
Comments
Recently somebody asked me to clarify one of the exception guidelines . They were asking whether it's ok to have a property on exception types that provides access to an error code. I added the following annotation to one of the guidelines: Do not...
Page 3 of 4 (100 items)
1
2
3
4