public bool Equals(SoldierMetaData other) { if (other == null) { return(false); } return(other.Id == this.Id && other.Name == this.Name); }
public override bool Equals(object other) { SoldierMetaData otherSoldierMetaData = other as SoldierMetaData; if (other == null || otherSoldierMetaData == null) { return(false); } if (other == this) { return(true); } return(this.Equals(otherSoldierMetaData)); }