/** * Initializes the node <tt>n</tt> associating it with the BitTorrent protocol and setting the * reference to the tracker, the status of the file and the bandwidth. * * @param n The node to initialize */ public void initialize(Node n) { Node tracker = Network.get(0); BitTorrent p; p = (BitTorrent) n.getProtocol(pid); p.setTracker(tracker); p.setThisNodeID(n.getID()); setFileStatus(p); setBandwidth(p); }