1
0
This commit is contained in:
2019-05-18 23:40:07 +02:00
parent fed17cd200
commit 71e650e373
5 changed files with 129 additions and 71 deletions

View File

@@ -10,5 +10,23 @@ namespace TMI_practicum
X = x;
Y = y;
}
public override int GetHashCode()
{
return X.GetHashCode() ^ Y.GetHashCode();
}
public override bool Equals(object obj)
{
return obj is Intersection && this == (Intersection) obj;
}
public static bool operator ==(Intersection x, Intersection y)
{
return x.X == y.X && x.Y == y.Y;
}
public static bool operator !=(Intersection x, Intersection y)
{
return !(x == y);
}
}
}