com.isti.util.test
Class DownloadFileTest

java.lang.Object
  extended by java.lang.Thread
      extended by com.isti.util.IstiThread
          extended by com.isti.util.IstiNotifyThread
              extended by com.isti.util.FileDownloader
                  extended by com.isti.util.test.DownloadFileTest
All Implemented Interfaces:
CallBackStringParam, java.lang.Runnable

public class DownloadFileTest
extends FileDownloader
implements CallBackStringParam


Nested Class Summary
 
Nested classes/interfaces inherited from class java.lang.Thread
java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler
 
Field Summary
 
Fields inherited from class com.isti.util.IstiThread
DEFAULT_TERMINATE_WAIT_TIME, terminateFlag
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
DownloadFileTest(java.lang.String fileNameStr, java.io.File outputDir, ProgressDialog dialogObj, ProgressIndicatorInterface progressBarObj, boolean unzipDownloadedFileFlag)
           
 
Method Summary
 void callBackMethod(java.lang.String str)
          Method called by the implementing class.
protected  void initProgressBar()
          Initialize the progress bar.
static void main(java.lang.String[] args)
           
protected  void unzipZipFile()
          Unzip the file.
 
Methods inherited from class com.isti.util.FileDownloader
backupOutputFile, checkConnection, checkHttpURLConnection, checkLastModified, checkLastModified, closeStreams, createOutputFileObject, createURL, doThreadFinished, getBackupFile, getDialogObj, getFileNameStr, getOutputFileObj, getProgressBarObj, isCloseWhenDone, isDownloadDone, requestDialogFocus, run, setBackupFile, setCallBackObj, setCheckConnection, setCheckLastModified, setCloseWhenDone, setDeleteFileAfterUnzip, setDownloadDone, setFileNameStr, terminate, terminateThread, threadFinished, transferStream
 
Methods inherited from class com.isti.util.IstiNotifyThread
sleep
 
Methods inherited from class com.isti.util.IstiThread
clearThreadWaitNotifyFlag, isTerminated, nextThreadNum, notifyThread, start, terminate, waitForNotify, waitForNotify, waitForTerminate, waitForTerminate, wasStarted
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, stop, stop, suspend, toString, yield
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DownloadFileTest

public DownloadFileTest(java.lang.String fileNameStr,
                        java.io.File outputDir,
                        ProgressDialog dialogObj,
                        ProgressIndicatorInterface progressBarObj,
                        boolean unzipDownloadedFileFlag)
Method Detail

callBackMethod

public void callBackMethod(java.lang.String str)
Method called by the implementing class.

Specified by:
callBackMethod in interface CallBackStringParam
Parameters:
str - string parameter to be passed.

initProgressBar

protected void initProgressBar()
Initialize the progress bar.

Overrides:
initProgressBar in class FileDownloader

unzipZipFile

protected void unzipZipFile()
                     throws java.io.IOException,
                            java.util.zip.ZipException
Unzip the file.

Overrides:
unzipZipFile in class FileDownloader
Throws:
java.util.zip.ZipException - if a ZIP error has occurred.
java.io.IOException - if an I/O error has occurred.

main

public static void main(java.lang.String[] args)