spair.ned 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. //
  2. // Pair scenario file for the sockets pair example.
  3. //
  4. package inet.examples.httptools.socket.pairsocket;
  5. import inet.applications.httptools.configurator.HttpController;
  6. import inet.networklayer.configurator.ipv4.IPv4NetworkConfigurator;
  7. import inet.node.inet.StandardHost;
  8. network HttpSockPair
  9. {
  10. parameters:
  11. @display("bgb=474,374");
  12. types:
  13. channel gigabitline extends ned.DatarateChannel
  14. {
  15. parameters:
  16. delay = 0.1us;
  17. datarate = 1000Mbps;
  18. }
  19. submodules:
  20. configurator: IPv4NetworkConfigurator {
  21. parameters:
  22. // moduleTypes = "StandardHost";
  23. // nonIPModuleTypes = "";
  24. config = xml("<config><interface hosts='*' address='145.236.x.x' netmask='255.255.0.0'/></config>");
  25. @display("i=block/cogwheel");
  26. }
  27. controller: HttpController {
  28. parameters:
  29. @display("p=62,60;i=block/cogwheel");
  30. }
  31. srv: StandardHost {
  32. parameters:
  33. @display("p=170,188;i=device/server_l");
  34. }
  35. cli: StandardHost {
  36. parameters:
  37. @display("p=316,188;i=device/laptop_l");
  38. }
  39. connections:
  40. cli.ethg++ <--> gigabitline <--> srv.ethg++;
  41. }