Brendan's C# class