public bool HasEdge(int u, int v, Constants.D_TYPES s) { foreach (Direction d in childNodes[u]) { if ((d.n == v) && (d.d == s)) { return(true); } } return(false); }
public void AddEdge(int u, int v, Constants.D_TYPES d) { childNodes[u].Add(new Direction(v, d)); }
public Direction(int n, Constants.D_TYPES d) { this.n = n; this.d = d; }