public CompareTo ( object obj ) : int | ||
obj | object | The object to compare to. |
return | int |
public int CompareTo(object obj)
{
Html other;
try
{
other = (Html)obj;
}
catch (InvalidCastException)
{
throw new ArgumentException("obj is not an Html string");
}
if (this < other)
{
return -1;
}
if (this > other)
{
return 1;
}
return 0;
}