public KeyValuePair <T, HashSet <T> > GetVertex(T vertex) { return(AdjacencyList.FirstOrDefault(x => x.Key.X == vertex.X && x.Key.Y == vertex.Y)); }
public KeyValuePair <Position, HashSet <Position> > GetVertex(Position vertex) { return(AdjacencyList.FirstOrDefault(x => x.Key.X == vertex.X && x.Key.Y == vertex.Y)); }