| 67 |
|
bw.flush(); |
| 68 |
|
} |
| 69 |
|
|
| 70 |
+ |
public static void printLinkedList(BufferedWriter bw, LinkedList list) throws IOException{ |
| 71 |
+ |
bw.write("<table border=\"0\" align=\"center\">"); |
| 72 |
+ |
|
| 73 |
+ |
Iterator it = list.iterator(); |
| 74 |
+ |
while (it.hasNext()){ |
| 75 |
+ |
ReportPage rp = (ReportPage)it.next(); |
| 76 |
+ |
bw.write("<tr><td><font size=\"4\">"+rp.getMachineName()+"</font></td></tr>"); |
| 77 |
+ |
} |
| 78 |
+ |
|
| 79 |
+ |
bw.write("</table>"); |
| 80 |
+ |
bw.flush(); |
| 81 |
+ |
} |
| 82 |
+ |
|
| 83 |
|
public static void printGraph(BufferedWriter bw, String filename, int width, int height, int type, long startDate, long endDate) throws IOException{ |
| 84 |
|
|
| 85 |
|
String graphTitle = "Unknown time period"; |
| 93 |
|
graphTitle = "Hourly report from "+DateUtils.dateString(startDate)+" to "+DateUtils.dateString(endDate); |
| 94 |
|
scaleRow = " <tr><td> </td>"; |
| 95 |
|
for (long i = startDate; i < endDate; i+=DateUtils.secsPerHour/6){ |
| 96 |
< |
scaleRow += "<td align=\"center\" width=\""+(100/colspan)+"%\"><font size=\"2\">"+DateUtils.timeString(i)+"</font></td>"; |
| 96 |
> |
scaleRow += "<td align=\"left\" width=\""+(100/colspan)+"%\"><font size=\"2\">>"+DateUtils.timeString(i)+"</font></td>"; |
| 97 |
|
} |
| 98 |
|
scaleRow += "</tr>"; |
| 99 |
|
colspan = 6; |