Geeks With Blogs
Eron Wright - All Killer No Filler blog May 2004 Entries
Use C# comment styles to your advantage
Comments within a C# method body tend to A) make a problem statement then B) document the steps to solve the problem. The problem statements tend to be multi-line; the details of the solution tend to be single-line. I want the problem statements to stand out. Traditionally I use #region blocks to group the problems. Unfortunately, regions are single-line. They are also slightly more laborous to construct. Lately I have been using a triple-slash comment block at the top of the method body to state ......

Posted On Thursday, May 27, 2004 6:46 AM

HTTP GET Idempotence and ASP.NET
I am struck by the consequences of the experience Craig relates in this post: He is discussing a Wiki site that mysteriously had its page content rolled back to a previous version. Wiki pages generally contain a link to do this, and it is assumed that a human would follow it with caution. Turns out that GoogleBot crawled the site and what-do-you-know the content rolled back. The underlying problem ......

Posted On Wednesday, May 26, 2004 12:40 PM

C#: Properties versus getter methods
You might be wondering why some classes in the .NET Framework have properties, other classes have GetXXX methods, and some have a combination of the two. The reason is that the semantic, or meaning, is quite different. Consider this class: public class Customer{ public int CustomerID; public string FirstName; public string LastName; public Order[] GetOrders() { // do database work }} The CustomerID, FirstName, and LastName represent the customer state. The orders are derived from the customer state ......

Posted On Sunday, May 2, 2004 8:18 AM

Copyright © Eron Wright | Powered by: