I am very excited to be giving a Framework Design Guidelines talk at the PDC this year. Krzysztof and I think of this as our "victory lap" for publishing the Framework Design Guidelines 2nd Edition.
As we were talking about what to cover in this talk, Krys and I realized that it has been just about 10 years since we started that very first version of the Framework Design Guidelines. This is well before we started working on the book, in fact it was before .NET Framework 1.0 shipped or was even announced (which, btw, was at PDC2000).
We got to thinking about how things have changed, both in the guidelines and in the industry. Equally interesting is how much has stayed the same. I am particularly interested in what stayed the same over that time.. As we wrote even those first guidelines we knew it was very important that they last. In fact, we needed them to be timeless. About the same time a friend was in the process of designing and building her own home and she gave be a book that still shapes the way I think about software design today: Christopher Alexander, The Timeless Way of Building.
11. EmployeeList l = FillList(); for (int i = 0; i < l.Length; i++){ if (l.All[i] == x){...} } if (l.GetAll()[i]== x) {...} public Employee[] All {get{}} public Employee[] GetAll() {} Moral: Use method if the operation is expensive Calling Code
30. public class TheBase : Object { public override string ToString() { return “Hello from the Base"; } } public class Derived : TheBase { public override string ToString() { return “Hello from Derived"; } }
31. Derived d = new Derived(); Console.WriteLine (d.ToString()); TheBase tb = d; Console.WriteLine (tb.ToString()); Object o = tb; Console.WriteLine (o.ToString());
38. Careful dependency management is the necessary ingredient to successful evolution of frameworks. Without it, frameworks quickly deteriorate and are forced out of relevance prematurely.