2 * Copyright (c) 2006-2013. The SimGrid Team.
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms of the license (GNU LGPL) which comes with this package.
9 import java.util.ArrayList;
11 import org.simgrid.msg.Task;
14 * Task exchanged between the tracker
17 public class TrackerTask extends Task {
26 public String hostname;
27 public String mailbox;
30 public int downloaded;
32 public double interval;
33 public ArrayList<Integer> peers;
35 public TrackerTask(String hostname, String mailbox, int peerId) {
36 this(hostname, mailbox, peerId, 0, 0, Common.FILE_SIZE);
38 public TrackerTask(String hostname, String mailbox, int peerId, int uploaded, int downloaded, int left) {
39 super("", 0, Common.TRACKER_COMM_SIZE);
40 this.type = Type.REQUEST;
41 this.hostname = hostname;
42 this.mailbox = mailbox;
44 this.uploaded = uploaded;
45 this.downloaded = downloaded;
47 this.peers = new ArrayList<Integer>();