computeRIPRoutes<T> function

RoutingTable<T> computeRIPRoutes<T>(
  1. Map<T, Map<T, num>> network,
  2. T sourceNode, {
  3. int maxHops = 15,
})

Convenience function for quick route computation

network - Network topology as adjacency list sourceNode - Source node for routing table maxHops - Maximum hop count (default: 15)

Returns complete routing table from source node

Throws ArgumentError if source node doesn't exist in network

Implementation

RoutingTable<T> computeRIPRoutes<T>(
  Map<T, Map<T, num>> network,
  T sourceNode, {
  int maxHops = 15,
}) {
  return RIPAlgorithm<T>().computeRoutes(network, sourceNode, maxHops: maxHops);
}