com.gubutech.xload.progress
Class XloadProgressData

java.lang.Object
  extended bycom.gubutech.xload.progress.XloadProgressData

public class XloadProgressData
extends java.lang.Object

Class that encapsulates a particular upload and the data associated with it.

Since:
1.2

Constructor Summary
XloadProgressData(long totalExpected)
          Creates an instance of XloadProgressData encapsulating the data required for an individual upload.
 
Method Summary
 int getFilesUploaded()
          Retrieves the number of files uploaded at any one time.
 int getOverallSpeed()
          Retrieves the overall speed during the whole of the upload in kilobytes per second.
 int getOverallTimeTaken()
          Retrieves the overall time taken to upload in seconds.
 int getPercent()
          Retrieves the total bytes read as a percentage of the total bytes to read.
 int getSecondsLeft()
          Retrieves the number of seconds left for this upload based on the speed at the time of this method call.
 int getSpeed()
          Retrieves the speed of upload in kilobytes per second at any one time.
 int getTotalRead()
          Retrieves the total bytes read at any one time (in kilobytes).
 int getUploadSize()
          Retrieves the total size of the upload in kilobytes.
 void setProgress(long totalRead, int filesUploaded)
          Sets the progress data for an individual upload at the time when this method is called.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XloadProgressData

public XloadProgressData(long totalExpected)
Creates an instance of XloadProgressData encapsulating the data required for an individual upload.

Since:
1.2
Method Detail

setProgress

public void setProgress(long totalRead,
                        int filesUploaded)
Sets the progress data for an individual upload at the time when this method is called.

Since:
1.2

getTotalRead

public int getTotalRead()
Retrieves the total bytes read at any one time (in kilobytes).

Since:
1.2

getPercent

public int getPercent()
Retrieves the total bytes read as a percentage of the total bytes to read.

Since:
1.2

getSpeed

public int getSpeed()
Retrieves the speed of upload in kilobytes per second at any one time.

Since:
1.2

getOverallSpeed

public int getOverallSpeed()
Retrieves the overall speed during the whole of the upload in kilobytes per second.

Since:
1.2

getOverallTimeTaken

public int getOverallTimeTaken()
Retrieves the overall time taken to upload in seconds.

Since:
1.2

getUploadSize

public int getUploadSize()
Retrieves the total size of the upload in kilobytes.

Since:
1.2

getFilesUploaded

public int getFilesUploaded()
Retrieves the number of files uploaded at any one time.

Since:
1.2

getSecondsLeft

public int getSecondsLeft()
Retrieves the number of seconds left for this upload based on the speed at the time of this method call.

Since:
1.2