/** This method will be used for debugging purposes of the download queue
* @param menuInput
*/
private void dumpCommand(String menuInput) {
Log outputFile=null;
menuInput = menuInput.replaceFirst(menuInput.split(" ")[0]+" ", "");
if ((menuInput.equalsIgnoreCase("dump"))||
(menuInput.equalsIgnoreCase("urldownloads"))){
outputFile = data.getDebugFile();
if (outputFile!=null){
DateFormat dateFormat = new SimpleDateFormat("dd/MM/yy HH:mm:ss");
Date date = new Date();
outputFile.println("--URLDownload Contents - "+dateFormat.format(date)+" --");
outputFile.println("DownladURL,status,destination,podcastid");
for (URLDownload currentDownload : data.getUrlDownloads().getDownloads()){
outputFile.println(currentDownload.getURL().toString()+
","+currentDownload.getCurrentStatus()+
","+currentDownload.getDestination()+
","+currentDownload.getPodcastId());
}
outputFile.println("-- URLDownload Contents end --");
}
}
}