Package ons
Class TrafficGenerator
java.lang.Object
ons.TrafficGenerator
public class TrafficGenerator
extends java.lang.Object
Generates the network's traffic based on the information passed through the
command line arguments and the XML simulation file.
-
Constructor Summary
Constructors Modifier Constructor Description protectedTrafficGenerator(org.w3c.dom.Element xml, double forcedLoad, PhysicalTopology pt)Creates a new TrafficGenerator object. -
Method Summary
Modifier and Type Method Description voidgenerateTraffic(PhysicalTopology pt, EventScheduler events, int seed)Generates the network's traffic.intgetCalls()
-
Constructor Details
-
TrafficGenerator
Creates a new TrafficGenerator object. Extracts the traffic information from the XML file and takes the chosen load and seed from the command line arguments.- Parameters:
xml- file that contains all information about the simulationforcedLoad- range of offered loads for several simulationspt- the PhysicalTopology object
-
-
Method Details
-
getCalls
public int getCalls() -
generateTraffic
Generates the network's traffic.- Parameters:
events- EventScheduler object that will contain the simulation eventspt- the network's Physical Topologyseed- a number in the interval [1,25] that defines up to 25 different random simulations
-