Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Update copyright lines with new year.
[simgrid.git] / examples / s4u / app-bittorrent / s4u-bittorrent.hpp
index 0895354..1c53685 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2012-2019. The SimGrid Team.
+/* Copyright (c) 2012-2020. The SimGrid Team.
  * All rights reserved.                                                     */
 
 /* This program is free software; you can redistribute it and/or modify it
@@ -7,8 +7,8 @@
 #ifndef BITTORRENT_BITTORRENT_HPP_
 #define BITTORRENT_BITTORRENT_HPP_
 
-#include <random>
 #include <simgrid/s4u.hpp>
+#include <xbt/random.hpp>
 
 constexpr char TRACKER_MAILBOX[] = "tracker_mailbox";
 /** Max number of peers sent by the tracker to clients */
@@ -77,15 +77,4 @@ public:
       : type(type), peer_id(peer_id), return_mailbox(return_mailbox), piece(piece){};
 };
 
-class HostBittorrent {
-  simgrid::s4u::Host* host = nullptr;
-
-public:
-  explicit HostBittorrent(simgrid::s4u::Host* ptr) : host(ptr) {}
-  HostBittorrent(const HostBittorrent&) = delete;
-  HostBittorrent& operator=(const HostBittorrent&) = delete;
-};
-
-extern std::default_random_engine generator;
-
 #endif /* BITTORRENT_BITTORRENT_HPP_ */