Пример #1
0
    public override bool Equals(object obj)
    {
        if (ReferenceEquals(null, obj))
        {
            return(false);
        }

        if (ReferenceEquals(this, obj))
        {
            return(true);
        }

        if (obj.GetType() != this.GetType())
        {
            return(false);
        }

        PathNode other = (PathNode)obj;

        return(!System.Object.ReferenceEquals(null, CurLocation) &&
               CurLocation.Equals(other.CurLocation));
    }
Пример #2
0
 public override bool IsGoalState()
 {
     return(CurLocation.Equals(dest));
 }