sbIMediaItemDownloadJob Interface Reference

import"sbIMediaItemDownloadJob.idl";

Inheritance diagram for sbIMediaItemDownloadJob:
[legend]
Collaboration diagram for sbIMediaItemDownloadJob:
[legend]

Public Member Functions

void start ()
 
- Public Member Functions inherited from sbIJobProgress
nsIStringEnumerator getErrorMessages ()
 Enumerate all the errors encountered during the job. More...
 
void addJobProgressListener (in sbIJobProgressListener aListener)
 Add a listener to be notified when significant job progress has been made. More...
 
void removeJobProgressListener (in sbIJobProgressListener aListener)
 Remove a previously added listener. More...
 

Public Attributes

readonly attribute nsIFile downloadedFile
 
readonly attribute sbIPropertyArray properties
 
attribute sbITemporaryFileFactory temporaryFileFactory
 
- Public Attributes inherited from sbIJobProgress
const unsigned short STATUS_FAILED = 0x00
 Constant indicating that the job has completed with errors. More...
 
const unsigned short STATUS_SUCCEEDED = 0x10
 Constant indicating that the job has completed. More...
 
const unsigned short STATUS_RUNNING = 0x20
 Constant indicating that the job is active. More...
 
readonly attribute unsigned short status
 Current status of the job. More...
 
readonly attribute boolean blocked
 If true, progress of job is blocked (e.g., due to locked resource). More...
 
readonly attribute AString statusText
 Localized message describing the status of the job. More...
 
readonly attribute AString titleText
 Localized message describing the type or purpose of the job. More...
 
readonly attribute unsigned long progress
 Number of work units completed. More...
 
readonly attribute unsigned long total
 Total number of work units to be completed May be set to 0 if the job length is indeterminate. More...
 
readonly attribute unsigned long errorCount
 Number of errors that have been encountered. More...
 

Detailed Description

This interface is implemented by media item download jobs. These jobs are created by media item downloaders to download media items and provide download progress and status. These jobs download media items for a target library. However, they do not add a media item to the target library. By default, the target library is the main library. The target library may be a device library. In this case, the media item download job may download a file format that is compatible with the device.

All implementors of sbIMediaItemDownloadJob must implement sbIJobCancelable.

TODO: Add a writable temporaryFileFactory attribute to use to create the downloaded file.

See Also
sbIMediaItemDownloader.

Definition at line 57 of file sbIMediaItemDownloadJob.idl.

Member Function Documentation

void sbIMediaItemDownloadJob::start ( )

Start the download.

Member Data Documentation

readonly attribute nsIFile sbIMediaItemDownloadJob::downloadedFile

When the download completes, final downloaded file. This file may be temporary and may be deleted when the download job object is destroyed.

Definition at line 63 of file sbIMediaItemDownloadJob.idl.

readonly attribute sbIPropertyArray sbIMediaItemDownloadJob::properties

Array of properties for the downloaded media item. These may be different from the properties for the source media item (e.g., DRM protection, bit rate).

Definition at line 70 of file sbIMediaItemDownloadJob.idl.

attribute sbITemporaryFileFactory sbIMediaItemDownloadJob::temporaryFileFactory

Temporary file factory to use for any temporary files.

Definition at line 75 of file sbIMediaItemDownloadJob.idl.


The documentation for this interface was generated from the following file: