Exemplo n.º 1
0
        /// <summary>
        /// Creates a new instance of this class.
        /// </summary>
        /// <param name="bInsertOSRoutesOnStrartup">A bool indicating whether routes from the operating system should be imported on startup.</param>
        public Router(bool bInsertOSRoutesOnStrartup)
        {
            lRoutedTrafficAnalyzer = new List <TrafficAnalyzer>();
            rtRoutingtable         = new RoutingTable();
            iRoutedPackets         = 0;
            bExcludeMulticast      = true;
            if (bInsertOSRoutesOnStrartup)
            {
                RoutingEntry[] arEntries = SystemRouteQuery.GetOSRoutes();

                foreach (RoutingEntry re in arEntries)
                {
                    this.rtRoutingtable.AddRoute(re);
                }
            }
        }
Exemplo n.º 2
0
 /// <summary>
 /// Creates a new instance of this class.
 /// </summary>
 /// <param name="reEntry">The routing entry</param>
 /// <param name="rtOwner">The routing table owning the routing entry</param>
 public RoutingTableEventArgs(RoutingEntry reEntry, RoutingTable rtOwner)
 {
     this.reEntry = reEntry;
     this.rtOwner = rtOwner;
 }