Go to home page mail me! RSS Feed

March 2010 Entries

TryParse on nullable types

For some unknown reason you can’t do a TryParse on nullable types or should I say the out parameter of a TryParse can not be nullable? For example this just won’t work. DateTime? dt; DateTime.TryParse("12/12/2010", out dt); Error 4 The best overloaded method match for 'System.DateTime.TryParse(string, out System.DateTime)' has some invalid arguments The solution or workaround is to use two variables to accomplish the goal, here is an example. DateTime? dt1; DateTime dt2; dt1 = DateTime.TryParse("12/12/2010", out dt2) ? dt2 : (DateTime?)null;

posted @ Saturday, March 13, 2010 3:37 PM | Feedback (0)

Taking my key value store to another level

Before I start cramming code, I’ll like to know what you guys think. I’ve been working heavily on my key value store and it has been working as expected, however, the main reason for me building this store does not seem to be completely eliminated with the functionalities that I have in place so far. therefore, I’ll like to add an extra piece to the jigsaw but before I do so I’ll like to hear what you have to say. The storage engine itself is solid and it works with the minimal functionalities that it currently has. As a...

posted @ Saturday, March 06, 2010 8:40 PM | Feedback (0)

Next entries »