Fredrik Normén
Any fool can write code that a computer can understand. Good programmers write code that humans can understand - Fowler
Sign in
|
Join
Home
RSS
Atom
Comments RSS
Search
Tags
.Net
AOP
ASP.Net
AXAJ
C#
Code
Defensive Programming
Desigm
Design By Contract
Multiple return values
MVC Framework
Patterns
Write code
Sponsors
advertise here
Navigation
Home
Blogs
Archives
May 2008 (5)
April 2008 (9)
March 2008 (3)
February 2008 (1)
January 2008 (1)
November 2007 (14)
About
Blogroll
ScottGu's Blog
Johan Lindfors
Nikhil Kothari
Johan Normén
My old blog, for archive purpose
Roger Alsing
Tips
Recent Posts
12
Comments
Avoid returning "null" and use the Null Object pattern?
by
Fredrik N
When I build applications and add methods to return a list of objects, I make it robust. So I always return an instance of the list instead or returning null. The reason is because I like the use of Count and also use foreach. I don't want to add extra...
22
Comments
Avoid "else" as much as possible, use "?:" instead
by
Fredrik N
To have a 10 week old baby Chihuahua takes a lot of time… the housekeeping is not so easy. I need to go up twice at night to let the little baby boy do his stuff. But it’s really wonderful to have such a small dog in my home, I bought a lot...
13
Comments
Use "constraints" instead of argument validation for int and double etc
by
Fredrik N
I will still continue with the argument validation track in this post also, I think it's an interesting topic. If you haven't read my earlier posts about this topic, take a look at the following posts on my blog: http://weblogs.asp.net/fredriknormen/archive...
33
Comments
How to validate a method's arguments?
by
Fredrik N
Yesterday I wrote a post about developers that skip validation of arguments . In this post I will give some example of how validation can be done. There are probably better way to do it, and that is why I need your feedback and comments. The first example...
14
Comments
Lazy Developers?
by
Fredrik N
When I was out with my new dog (I Chihuahua, wonderful dog), I was thinking about Defensive Programming and Design by Contract. I like to do some refactoring and help other people to write cleaner code etc, not that I’m an expert in the area but I think...
Filed under:
Design By Contract
,
Defensive Programming
,
Code
4
Comments
I also want Spec#
by
Fredrik N
I will copy Greg Young ! I also want Spec#. If you also wants it, please let Microsoft know about it. Something I like with Spec# is the support for Design by Contract. I want verifiable software... I WANT SPEC#! Here is an old post about...
5
Comments
Why can't I be satisfied when I'm looking back on old applications?
by
Fredrik N
Most of the time I build an application I have the feeling "this is going to be a great app. Good design, nice written code and a perfect application". I think most of you had the same feeling sometimes. But when I look back on previous...
9
Comments
The configurable application, no need for recompilation and new deployment!
by
Fredrik N
The following I will write about is something I have used in some projects to see if it gives me any value, I haven't seen any evolutionary results yet, but maybe it's because I often move along to other projects when the previous one is completed ;)...
Filed under:
C#
,
Write code
,
Desigm
,
Patterns
0
Comments
Can the use of Extension methods break the Law of Demeter?
by
Fredrik N
To make an easy description of Law of Demeter we can summarize it to the following sentence: “In particular, an object should avoid invoking methods of a member object returned by another method.” What does this has to do with Extension methods...
11
Comments
What purpose does the Repository Pattern have?
by
Fredrik N
I have watch Rob Conery’s great screencast about MVC Storefront . If you haven’t seen them, you should take a look. Really interesting, he build and app by using Agile, "TDD" etc. I have some comments about his implementation I want...
More Posts
Next page »