Skip to content

Instantly share code, notes, and snippets.

@bdallen
Created November 8, 2011 05:50
Show Gist options
  • Save bdallen/1347115 to your computer and use it in GitHub Desktop.
Save bdallen/1347115 to your computer and use it in GitHub Desktop.
Hmmm....
public class DHCPLease : IComparer
{
public virtual string ID { get; set; }
public virtual string Name { get; set; }
public virtual string IPAddress { get; set; }
public virtual string BindState { get; set; }
public virtual string NextBindState { get; set; }
int IComparer.Compare(object obj1, object obj2)
{
DHCPLease a, b;
a = (DHCPLease)obj1;
b = (DHCPLease)obj2;
return a.Name.CompareTo(b.Name);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment