Beispiel #1
0
 def execute(self, net_sim: sim.NetSimulation):
     print(f'Creating switch: {self.switch_name}')
     switch = dv.Switch(self.switch_name, self.ports_count,
                        net_sim.signal_time)
     net_sim.add_device(switch)
Beispiel #2
0
 def execute(self, net_sim: sim.NetSimulation):
     print(f'Creating hub: {self.hub_name}')
     hub = dv.Hub(self.hub_name, self.ports_count)
     net_sim.add_device(hub)
Beispiel #3
0
 def execute(self, net_sim: sim.NetSimulation):
     print(f'Creating host: {self.host_name}')
     host = dv.Host(self.host_name, net_sim.signal_time)
     net_sim.add_device(host)
Beispiel #4
0
 def execute(self, net_sim: sim.NetSimulation):
     print(f'Creating router: {self.router_name}')
     router = dv.Router(self.router_name, self.ports_count,
                        net_sim.signal_time)
     net_sim.add_device(router)