public object Clone() { Bad7 result = new Bad7(); result.name = name; // missing address return(result); }
public override bool Equals(object obj) { Bad7 rhs = obj as Bad7; if ((object)rhs == null) { return(false); } return(this == rhs); }
// Equals uses name and foo, == uses name and address. public override bool Equals(object rhsObj) { if (rhsObj == null) { return(false); } Bad7 rhs = rhsObj as Bad7; return(name == rhs.Name && foo == rhs.foo); }
public bool Equals(Bad7 rhs) { return this == rhs; }
public bool Equals(Bad7 rhs) { return(this == rhs); }