• Share
  • Email
  • Embed
  • Like
  • Save
  • Private Content
Framework Design Guidelines
 

Framework Design Guidelines

on

  • 18,284 views

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. ...

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.

Statistics

Views

Total Views
18,284
Views on SlideShare
18,082
Embed Views
202

Actions

Likes
21
Downloads
658
Comments
0

12 Embeds 202

http://blog.lastmind.net 87
http://lastmind.net 67
http://www.slideshare.net 28
http://www.hanrss.com 10
http://photoudo.com 2
http://djajar.com 2
http://feeds.feedburner.com 1
http://www.photoudo.com 1
http://static.slideshare.net 1
http://team.malltb.com 1
http://www.techgig.com 1
http://webcache.googleusercontent.com 1
More...

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment
  • 06/05/09 19:20 © 2008 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

Framework Design Guidelines Framework Design Guidelines Presentation Transcript

  •  Krzysztof Cwalina Program Manager Microsoft Corporation http://blogs.msdn.com/kcwalina
    •  Brad Abrams
    • Product Unit Manager
    • Microsoft Corporation http://blogs.msdn.com/brada
  •  
  • Dow Jones Industrial Average @ 9,000
  • Dow Jones Industrial Average @ 9,000
  •  
  •  
    • Framework Design Artifacts:
    • Properties
    • Methods
    • Events
    • Constructors
  • public class XmlFile { string filename; Stream data; public XmlFile(string filename) { this.data = DownloadData(filename); } } public XmlFile(string filename) { this.filename = filename; } lazy
  • public class ArrayList { public int Count {get;} }
  •  
  • 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
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  • Time to cut…
  •  
  •  
  •  
  • public class TheBase : Object { public override string ToString() { return “Hello from the Base&quot;; } } public class Derived : TheBase { public override string ToString() { return “Hello from Derived&quot;; } }
  • Derived d = new Derived(); Console.WriteLine (d.ToString()); TheBase tb = d; Console.WriteLine (tb.ToString()); Object o = tb; Console.WriteLine (o.ToString());
  •  
    • All Virtual members should define a contract
    • Don’t require clients to have knowledge of your overriding
    • Should you call the base?
  • Barbara Liskov
  • public interface IComparable { int CompareTo(object obj); }
  •  
  •  
  • Careful dependency management is the necessary ingredient to successful evolution of frameworks. Without it, frameworks quickly deteriorate and are forced out of relevance prematurely.
  •  
  •    BCL WPF XML Reflection
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  • Climbing a mountain?
  • Scaling a peak?
  • Running across a desert?
  • Falling into a pit?
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
  •  
    • Read the manual??
  •  
  •  
  •  
  •  
  • The Power of Sameness
    • P ascal C asing – Each word starts with an uppercase letter
    • c amel C asing – First word lower case, others uppercase
    • SCREAMING_CAPS – All upper case with underscores
  • public class MemberDoc { public int CompareTo(object value) public s tring Name { get;} }
  • public class CMyClass { int CompareTo (object objValue) {..} string lpstrName {get;} int iValue {get;} }
  •  
  •  
  •  
  •  
  •  
  •  
  • Brad Abrams http://blogs.msdn.com/brada Krzysztof Cwalina http://blogs.msdn.com/kcwalina Please fill out the session evals!
  • © 2008 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.