public int CompareTo(object obj) { if (obj == null) return 1; CacheObject other = obj as CacheObject; if (other != null) return other.CentreDistance.CompareTo(CentreDistance); else return 1; }