/// <summary>Compare 2 ArchivingActor objects. They are identical if they have the same FullName</summary> public int CompareTo(object obj) { if (obj == null) { return(1); } ArchivingActor other = obj as ArchivingActor; if (other == null) { throw new ArgumentException(); } var fullNameCompare = String.Compare(GetFullName(), other.GetFullName(), StringComparison.OrdinalIgnoreCase); var nameCompare = String.Compare(GetName(), other.GetName(), StringComparison.OrdinalIgnoreCase); return(nameCompare == 0 ? 0 : fullNameCompare); }
/// <summary>Compare 2 ArchivingActor objects. They are identical if they have the same FullName</summary> public static int Compare(ArchivingActor actorA, ArchivingActor actorB) { return(actorA.CompareTo(actorB)); }