import javax.swing.table.AbstractTableModel;
import net.pterodactylus.jsite.core.Request;
+import net.pterodactylus.jsite.core.Request.Type;
import net.pterodactylus.util.logging.Logging;
/**
private static final Logger logger = Logging.getLogger(RequestTableModel.class.getName());
/** The column names. */
- private static final String[] COLUMN_NAMES = new String[] { "ID", "Progress" };
+ private static final String[] COLUMN_NAMES = new String[] { "ID", "Progress", "Type" };
/** The requests. */
private final List<Request> requests = Collections.synchronizedList(new ArrayList<Request>());
return "unknown";
}
return String.valueOf((request.getSuccessfulBlocks() * 10000 / request.getRequiredBlocks()) / 100.0) + "%";
+ case 2:
+ return ((request.getType() != null) ? request.getType() : Type.unknown).name();
}
return null;
}