Here's a clean solution to doing recursive hierarchical joins in LINQ and C#. I couldn't find an example that didn't use an intermediate "node" class, so I'd like to introduce my approach which provides extension methods to IEnumerabe<T> for doing re...
Filed under:
Algorithms
C#
LINQ
I recently implemented a pager in ASP.NET MVC and thought it would be worth sharing. It uses fluent syntax - a technique I've not seen used much in MVC to solve similar problems so I thought I'd throw it out there! At first glance, MVC has a much mor...
Filed under:
ASP.NET
C#
MVC
The Google +1 button lets visitors to your site recommend and share your content. I've created an ASP.NET server control to encapsulate the JavaScript you need to embed on your page. Using my server control you don't need to keep visiting the Google...
Filed under:
ASP.NET
C#
Google Plus
Whenever I find myself needing to use a symmetric encryption algorithm, I always seem to write more or less the same code substituting whichever built in .NET cryptography class I need to use. So I decided to write a generic encrypt/decrypt cipher ut...
Filed under:
C#
Cryptography
Security
The Event Broker is an implementation of the Observer
pattern. The key benefit of an Event Broker is that it offers a loosely coupled mechanism to
broadcast and receive events. This is especially useful in ASP.NET where you
want to raise events in on...
Filed under:
ASP.NET
C#
Patterns
The AVL tree is a rigorously balance binary search tree with very fast and stable insert, delete and search times. I like the various .NET dictionaries but have been unimpressed by their performance. So, after researching efficient dictionary algorit...
Filed under:
Algorithms
C#
Performance