|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.lastbamboo.common.download.DownloaderState.AbstractRunning
org.lastbamboo.common.download.MsDState.LibTorrentDownloadingState
public static class MsDState.LibTorrentDownloadingState
An implementation of the LibTorrent downloading state.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface org.lastbamboo.common.download.DownloaderState |
|---|
DownloaderState.AbstractFailed, DownloaderState.AbstractRunning, DownloaderState.AbstractSucceeded |
| Field Summary |
|---|
| Fields inherited from interface org.lastbamboo.common.download.MsDState |
|---|
CANCELED, COMPLETE, COULD_NOT_DETERMINE_SOURCES, FAILED, GETTING_SOURCES, IDLE, NO_SOURCES_AVAILABLE |
| Constructor Summary | |
|---|---|
MsDState.LibTorrentDownloadingState(int bytesPerSecond,
int numSources,
long bytesRead,
int numFiles,
long maxByte,
long size)
Constructs a new downloading state. |
|
| Method Summary | ||
|---|---|---|
|
accept(MsDState.Visitor<T> visitor)
Accepts a visitor to this state. |
|
boolean |
equals(Object obj)
|
|
long |
getBytesRead()
Accessor for the number of bytes read. |
|
double |
getKbs()
Returns the speed of the download in kilobytes per second. |
|
long |
getMaxContiguousByte()
Returns the maximum contiguous byte we've read for this download. |
|
int |
getNumFiles()
Gets the number of files in this torrent. |
|
int |
getNumSources()
Returns the number of sources used by the download. |
|
String |
getTimeRemaining()
Accessor for the time remaining. |
|
int |
hashCode()
|
|
| Methods inherited from class org.lastbamboo.common.download.DownloaderState.AbstractRunning |
|---|
calculateTimeRemaining, getType |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.lastbamboo.common.download.DownloaderState |
|---|
getType |
| Constructor Detail |
|---|
public MsDState.LibTorrentDownloadingState(int bytesPerSecond,
int numSources,
long bytesRead,
int numFiles,
long maxByte,
long size)
bytesPerSecond - The speed of the download in bytes per second.numSources - The number of sources used by the download.bytesRead - The number of bytes read.maxByte - The maximum contiguous byte we've read.numFiles - The number of files in the torrent.| Method Detail |
|---|
public <T> T accept(MsDState.Visitor<T> visitor)
MsDState
accept in interface MsDStateT - The return type of the visitor.visitor - The visitor.
public double getKbs()
MsDState.Downloading
getKbs in interface MsDState.Downloadingpublic int getNumSources()
MsDState.Downloading
getNumSources in interface MsDState.Downloadingpublic long getBytesRead()
MsDState.Downloading
getBytesRead in interface MsDState.Downloadingpublic long getMaxContiguousByte()
MsDState.LibTorrentDownloading
getMaxContiguousByte in interface MsDState.LibTorrentDownloadingpublic int getNumFiles()
MsDState.LibTorrentDownloading
getNumFiles in interface MsDState.LibTorrentDownloadingpublic String getTimeRemaining()
MsDState.Downloading
getTimeRemaining in interface MsDState.Downloadingpublic int hashCode()
hashCode in class Objectpublic boolean equals(Object obj)
equals in class Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||