-
-
Notifications
You must be signed in to change notification settings - Fork 738
module.PyFile.PyFile
class module.PyFile.PyFile(manager, id, url, name, size, status, error, pluginname, package, order)
Represents a file object at runtime
__init__(manager, id, url, name, size, status, error, pluginname, package, order)
The whole SourceCode can be found here: (SourceCode)
Methods
| Name | Description |
|---|---|
__init__(manager, id, url, name, size, ...) |
|
abortDownload() |
abort pyfile if possible |
checkIfProcessed() |
|
delete() |
delete pyfile from database |
finishIfDone() |
set status to finish and release file if every thread is finished with it |
formatETA() |
formats eta to readable format |
formatSize() |
formats size to readable format |
formatWait() |
formats and return wait time in humanreadable format |
getBytesLeft() |
gets bytes left |
getETA() |
gets established time of arrival |
getPercent() |
get % of download |
getSize() |
get size of download |
getSpeed() |
calculates speed |
getStatusName() |
|
hasPlugin(*args) |
|
hasStatus(status) |
|
initPlugin(*args) |
|
notifyChange() |
|
package() |
return package instance |
release(*args) |
|
setCustomStatus(msg[, status]) |
|
setProgress(value) |
|
setStatus(status) |
|
sync() |
sync PyFile instance with database |
toDbDict() |
return data as dict for databse |
toDict() |
return dict with all information for interface |
Attributes
| Name |
|---|
abort |
active |
error |
id |
lock |
m |
maxprogress |
name |
order |
packageid |
plugin |
pluginclass |
pluginmodule |
pluginname |
progress |
reconnected |
size |
status |
statusname |
url |
waitUntil |
The whole SourceCode can be found here: (SourceCode)
####package()
return package instance
####sync()
sync PyFile instance with database
####delete()
delete pyfile from database
####toDict()
return dict with all information for interface
####toDbDict()
return data as dict for databse
format:
{ id: {‘url’: url, ‘name’: name ... } }
####abortDownload()
abort pyfile if possible
####finishIfDone()
set status to finish and release file if every thread is finished with it
####formatWait()
formats and return wait time in humanreadable format
####formatSize()
formats size to readable format
####formatETA()
formats eta to readable format
####getSpeed()
calculates speed
####getETA()
gets established time of arrival
####getBytesLeft()
gets bytes left
####getPercent()
get % of download
####getSize()
get size of download
This page may no longer be valid. If you find something wrong, please report it.