Feed on
Posts
Comments

Category Archive for 'C#'

Automatic properties in .NET 3.5 are a nice thing, but they are out of the equation if you want to take advantage of the almighty INotifyPropertyChanged interface which plays a crucial role in WPF. Here’s a set of ReSharper snippets that simplify interface implementation and property declaration.
Event Declaration
The first snippet just prints out an interface […]

Read Full Post »

A KeyedCollection for int keys

I’m using this class so much that I thought I’d share it with you. This generic class is an implementation of the KeyedCollection<TKey, TItem> class for items that have a numeric key:
public abstract class NumericallyKeyedCollection<T> : KeyedCollection<int, T>{ }
Using int-Keys takes a bit more work than other types, because KeyedCollection provides indexers for both key […]

Read Full Post »