Brunet.Simulator.RelayOverlapSimulator.FindOverlapWorker C# (CSharp) Method

FindOverlapWorker() protected method

protected FindOverlapWorker ( Node node1, Node node2 ) : void
node1 Node
node2 Node
return void
    protected void FindOverlapWorker(Node node1, Node node2)
    {
      ConnectionList cl = node1.ConnectionTable.GetConnections(ConnectionType.Structured);
      IEnumerable ov = node1.ConnectionTable.GetConnections(Relay.OverlapConnectionOverlord.STRUC_OVERLAP);
      foreach(Connection ov_con in ov) {

        int index = cl.IndexOf(ov_con.Address);
        if(index < 0) {
          Console.WriteLine("No matching pair for overlap...");
          continue;
        }
        Connection con = cl[index];
        int delay = (ov_con.State.Edge as SimulationEdge).Delay + (con.State.Edge as SimulationEdge).Delay;
        Console.WriteLine("Delay: " + delay);
      }
    }