Krzysztof Cwalina

Designing Reusable Frameworks

Browse by Tags

Tagged Content List
  • Blog Post: Extensible Framework Design Studio Released

    This summer we had a high school intern, Nick Moloney, who worked on incorporating MEF into FDS . The fruits of his labor are now on code gallery. You can download the extensible FDS here . Congratulations to Nick! The current release has just a few extensibility points, but you should expect more...
  • Blog Post: API Design Myth: Exceptions are for "Exceptional Errors"

    I was updating FDG section on exceptions. I added one anntation that I thought I would post here as well: KRZYSZTOF CWALINA One of the biggest misconceptions about exceptions is that they are for “exceptional conditions.” The reality is that they are for communicating error...
  • Blog Post: Nullable<T> Usage Guidelines

    These guidelines were just added as part of an update to the Framework Design Guidelines book ( upcomming 2nd edition ). Hope you find them useful. Nullable<T> is a simple type added to the .NET Framework 2.0. The type was designed to be able to represent Value Types with “null” values. ...
  • Blog Post: Framework Design Guidelines Digest v2

    Almost 4 years ago, I blogged about Framework Design Guidelines Digest . At that time, my blog engine did not support attaching files and I did not have a convenient online storage to put the document on, and so I asked people to email me if they want an offline copy. Believe it or not, I still receive...
  • Blog Post: Framework Design Studio Released

    When I was coming back from Mix 2007, I was bored on the plane and so started to write a dev tool. What a geeky thing to do on a plane. :-) The tool allows comparing two versions of an assembly to identify API differences: API additions and removals. Comparing versions of APIs comes very handy during...
  • Blog Post: Simulated Covariance for .NET Generics

    I just wrote this pattern, but I am not sure if I should add it officially to the Framework Design Guidelines. It seems like a bit of a corner case scenario, though I do get questions about it from time to time. Anyway, let me know what you think. Different constructed types don’t have a common...
  • Blog Post: Job Openings on the .NET Framework Core Team

    We have been incubating ideas about building a simple extensibility framework for some time. Now, as plans for the next version of the .NET Framework crystallize a bit more, we decided to productize the project. As a result, we have opened a job position (and most probably will be opening more) on the...
  • Blog Post: Video Recording of "Framework Engineering: Architecting, Designing, and Developing Reusable Libraries"

    I just received a video recording of a talk I did at the last TechEd. You can find the abstract below, and the WMV file can be downloaded from here . Hope you find it useful. [UPDATE: I attched the slides in xps format. The ppt file is 10x larger] Framework Engineering: Architecting, Designing...
  • Blog Post: Framework Design Guidelines 2nd Edition

    My blog was relatively silent for several weeks. First, I was traveling to Europe for the TechEd, then was busy at work, then the holiday break. It's time to go back to more regular posting. I will start with an announcement (or at least a more formal and broader announcement): after my TechEd presentation...
  • Blog Post: What Do Swimmers Have to Say About Framework Design?

    I am starting to feel pressure to finish up slides for my presentation at the upcoming TechEd in Barcelona. I will be talking about framework architecture and design. Here is the abstract I took from the conference’s site : WIN304 Framework Engineering: Architecting, Designing, and Developing Reusable...
  • Blog Post: China Trip

    Sorry for not blogging for such a long time. First I was on a combined business/vacations trip to China and when I came back, I got involved in some intensive planning for the future releases of the platform. I will try to post something about software in the next couple of days. The trip to China...
  • Blog Post: FxCop Designers Honored with the Chairman's Award

    Last week, during the annual Engineering Excellence week, several Microsoft engineers and managers involved in development of engineering tools and practices were presented with Engineering Excellence Awards. In addition, the principal designers of three static analysis tools were honored with so called...
  • Blog Post: Generic Methods as Casts

    Somebody just asked me which of the following API design alternatives is better. They both do what we could call “casting.” // Generic Method “Cast” var foo = someInstance.SomeMethod<IFoo>(); // Simple Cast var foo = (IFoo) someInstance.SomeMethod(); The Generic method approach...
  • Blog Post: Framework design lecture avaliable for download

    I have good news for all who asked about an off line version of the API design lecture I blogged about a few weeks ago . After literally a hundred emails and comments on the blog (thanks for pushing me to get this done), weeks of trying to get this setup, including the difficulty of finding a server...
  • Blog Post: Nullable<bool> usage guideline

    I am starting to work on some updates to the framework design guidelines related to new framework and language features added in .NET 2.0, 3.0, and 3.5. One of such additions are the nullable types (Nullable<T>). Coincidentally, somebody asked me today whether they should use Nullable<bool>...
  • Blog Post: Online lecture on API design

    I gave a lecture on framework design at the Redmond’s Microsoft Research Center. They recorder and posted it on the Research Channel . You can see it here . It’s more than 3 hours long, but I think you will find it worth the time. Let me know what you think.
  • Blog Post: How to Design Exception Hierarchies

    I still get a lot of questions on how to design exception hierarchies, despite several attempts to describe it in talks, the FDG book, and in posts on this blog. Maybe the guidance gets lots in the in the complexities of the full guidance surrounding exception handling or I am a bad communicator. Let...
  • Blog Post: .NET Framework Performance Signatures

    I love Rico’s performance quizzes in general, but the last one has something especially interesting: a link to a file listing all members in the Framework and their estimated performance signatures (perf characteristic based on the number of allocations in the member). Now, I only wish I had an fxcop...
  • Blog Post: System.TimeZone2 Naming ... and related design guidelines

    There is an interesting discussion on the BCL blog about a new BCL type called TimeZone2. Just take a look at the comments below the System.TimeZone2 Starter Guide post. The new type supersedes an existing type called TimeZone (which is obsolete now). Lots of people are not thrilled with the “2” suffix...
  • Blog Post: Poll: Attribute Design

    I would like to run a quick poll. Which design do you prefer for a set of related attributes and why? Option #1: Several Attribute Types: public class AaaaFooAttribute: Attribute { } public class BbbbFooAttribute: Attribute { } public class CcccFooAttribute: Attribute { } public class...
  • Blog Post: Framewok Design Guidelines Wins Productivity Award

    A couple of months ago, Brad blogged about the FDG book getting into the Jolt Award finals. The winners were just announced and we have won the Productivity Award! I am shocked … that Brad did not blogged this information first! :-) On that occasion, I looked up some of the past winners of the...
  • Blog Post: Framework Design Humor by Benji Smith

    Benji wrote a pretty funny article exposing one of the main problems with bad APIs: trying to enable every single scenario at the wrong level of abstraction. In other words, when your APIs get too complex, think whether you are not trying to enable scenarios for which assembly level programming would...
  • Blog Post: Code Query Language

    Patrick Smacchia just released an alpha of an interesting application (NDepend) that can be used to analyze manage code binaries. It’s similar to FxCop . One really nice difference is that you can extend the tool using scripts written in CQL (code query language). It would be even better if the...
  • Blog Post: Krzysztof’s Laws of API Design

    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. Update: "usability" in this context means...
  • Blog Post: I don’t like the “Base” suffix

    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 base class? Or what do you call an abstract subclass...
Page 1 of 2 (43 items) 12