Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

jsd.download
Class Download  view Download download Download.java

java.lang.Object
  extended byjava.util.Observable
      extended byjsd.download.Download
All Implemented Interfaces:
java.lang.Runnable

public class Download
extends java.util.Observable
implements java.lang.Runnable


Nested Class Summary
(package private)  class Download.DownloadThread
           
(package private)  class Download.FtpDownloadThread
           
 
Field Summary
private  java.lang.String computer
           
private  boolean connected
           
private  java.lang.String filename
           
private  int filesize
           
private  boolean finished
           
private  java.lang.String fname
           
private  java.lang.String path
           
private  long progress
           
(package private) static java.util.Hashtable retryhash
           
private  java.lang.String share
           
private  long startTimeMillis
           
private  java.lang.String status
           
private  jsd.telnet.TelnetWrapper telnet
           
private  java.lang.Thread thisThread
           
 
Fields inherited from class java.util.Observable
 
Constructor Summary
Download(java.lang.String tfname)
           
 
Method Summary
 boolean doLogin()
           
static java.lang.String escape(java.lang.String str)
           
static java.lang.String escapeDoubleAndSingle(java.lang.String str)
           
(package private) static java.lang.String escapeRegEx(java.lang.String str)
           
 java.lang.String getComputer()
           
 java.lang.String getFilename()
           
 int getFilesize()
           
 java.lang.String getPath()
           
 long getProgress()
           
 java.lang.String getShare()
           
 long getStartTime()
           
 java.lang.String getStatus()
           
static boolean processNcReturnValue(java.lang.String s)
           
static java.lang.String replace(java.lang.String str, java.lang.String pattern, java.lang.String replace)
           
 void run()
          This method will be called by whoever wishes to run your class implementing Runnable.
 void startDownload()
           
 java.lang.String toString()
          Convert this Object to a human-readable String.
 
Methods inherited from class java.util.Observable
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

thisThread

private java.lang.Thread thisThread

filename

private java.lang.String filename

computer

private java.lang.String computer

share

private java.lang.String share

path

private java.lang.String path

filesize

private int filesize

progress

private long progress

status

private java.lang.String status

finished

private boolean finished

startTimeMillis

private long startTimeMillis

fname

private java.lang.String fname

telnet

private jsd.telnet.TelnetWrapper telnet

connected

private boolean connected

retryhash

static java.util.Hashtable retryhash
Constructor Detail

Download

public Download(java.lang.String tfname)
Method Detail

startDownload

public void startDownload()

escapeRegEx

static java.lang.String escapeRegEx(java.lang.String str)

escape

public static java.lang.String escape(java.lang.String str)

escapeDoubleAndSingle

public static java.lang.String escapeDoubleAndSingle(java.lang.String str)

replace

public static java.lang.String replace(java.lang.String str,
                                       java.lang.String pattern,
                                       java.lang.String replace)

getFilename

public java.lang.String getFilename()

getComputer

public java.lang.String getComputer()

getShare

public java.lang.String getShare()

getPath

public java.lang.String getPath()

getFilesize

public int getFilesize()

getProgress

public long getProgress()

getStatus

public java.lang.String getStatus()

getStartTime

public long getStartTime()

toString

public java.lang.String toString()
Description copied from class: java.lang.Object
Convert this Object to a human-readable String. There are no limits placed on how long this String should be or what it should contain. We suggest you make it as intuitive as possible to be able to place it into System.out.println() 55 and such.

It is typical, but not required, to ensure that this method never completes abruptly with a java.lang.RuntimeException.

This method will be called when performing string concatenation with this object. If the result is null, string concatenation will instead use "null".

The default implementation returns getClass().getName() + "@" + Integer.toHexString(hashCode()).


run

public void run()
Description copied from interface: java.lang.Runnable
This method will be called by whoever wishes to run your class implementing Runnable. Note that there are no restrictions on what you are allowed to do in the run method, except that you cannot throw a checked exception.

Specified by:
run in interface java.lang.Runnable

processNcReturnValue

public static boolean processNcReturnValue(java.lang.String s)

doLogin

public boolean doLogin()