Greg Beech's Website

July 2006 - Greg Beech's Tech Blog

  • Implementing object equality in .NET

    At first glance it seems simple to implement object equality in .NET, just override the Equals method inherited from System.Object, but in reality there actually are a lot of potential problems. You need to consider comparing null objects, and also the string representation, hash code and immutability of the object otherwise your application might behave oddly in specific circumstances. Here's...
Copyright (C) Greg Beech. All rights reserved.
Powered by Community Server (Non-Commercial Edition), by Telligent Systems