public override bool Equals(object obj) { PlanillaDetalle newObj = obj as PlanillaDetalle; if (newObj == null) { return(false); } else { return(id.Equals(newObj.id)); } }
public int CompareTo(object obj) { if (obj == null) { return(1); } PlanillaDetalle newObj = obj as PlanillaDetalle; if (newObj != null) { return(this.Id.CompareTo(newObj.Id)); } else { throw new ArgumentException("El objeto es incorrecto"); } }