import "sbIDevice.idl";
Inheritance diagram for sbIDevice:
Public Member Functions | |
void | connect () |
void | disconnect () |
nsIVariant | getPreference (in AString aPrefName) |
void | setPreference (in AString aPrefName, in nsIVariant aPrefValue) |
void | cancelRequests () |
void | syncLibraries () |
void | eject () |
Public Attributes | |
readonly attribute AString | name |
readonly attribute nsIDPtr | controllerId |
readonly attribute nsIDPtr | id |
readonly attribute boolean | connected |
readonly attribute boolean | threaded |
readonly attribute sbIDeviceCapabilities | capabilities |
readonly attribute sbIDeviceContent | content |
readonly attribute nsIPropertyBag2 | parameters |
readonly attribute sbIDeviceProperties | properties |
readonly attribute boolean | isBusy |
readonly attribute boolean | canDisconnect |
readonly attribute sbIDeviceStatus | currentStatus |
readonly attribute unsigned long | state |
const unsigned long | STATE_IDLE = 0 |
const unsigned long | STATE_SYNCING = 1 |
const unsigned long | STATE_COPYING = 2 |
const unsigned long | STATE_DELETING = 3 |
const unsigned long | STATE_UPDATING = 4 |
const unsigned long | STATE_MOUNTING = 5 |
const unsigned long | STATE_DOWNLOADING = 6 |
const unsigned long | STATE_UPLOADING = 7 |
const unsigned long | STATE_DOWNLOAD_PAUSED = 8 |
const unsigned long | STATE_UPLOAD_PAUSED = 9 |
const unsigned long | STATE_DISCONNECTED = 10 |
const unsigned long | STATE_BUSY = 11 |
const unsigned long | STATE_CANCEL = 12 |
const unsigned long | STATE_USER = 0x20000000 |
const unsigned long | REQUEST_FLAG_USER = 0x80000000 |
const unsigned long | REQUEST_FLAG_WRITE = 0x40000000 |
const unsigned long | REQUEST_MOUNT = 1 |
const unsigned long | REQUEST_READ = 2 |
const unsigned long | REQUEST_EJECT = 3 |
const unsigned long | REQUEST_SUSPEND = 4 |
const unsigned long | REQUEST_WRITE = REQUEST_FLAG_WRITE + 1 |
const unsigned long | REQUEST_DELETE = REQUEST_FLAG_WRITE + 2 |
const unsigned long | REQUEST_SYNC = REQUEST_FLAG_WRITE + 3 |
const unsigned long | REQUEST_WIPE = REQUEST_FLAG_WRITE + 4 |
const unsigned long | REQUEST_MOVE = REQUEST_FLAG_WRITE + 5 |
const unsigned long | REQUEST_UPDATE = REQUEST_FLAG_WRITE + 6 |
const unsigned long | REQUEST_NEW_PLAYLIST = REQUEST_FLAG_WRITE + 7 |
const unsigned long | REQUEST_FACTORY_RESET = REQUEST_FLAG_WRITE + 8 |
Definition at line 49 of file sbIDevice.idl.
void sbIDevice::connect | ( | ) |
Called when the device should initialize.
void sbIDevice::disconnect | ( | ) |
Called when the device is to finalize.
Device implementations must call sbIDeviceContent::Finalize
nsIVariant sbIDevice::getPreference | ( | in AString | aPrefName | ) |
Get a preference stored on the device.
void sbIDevice::setPreference | ( | in AString | aPrefName, | |
in nsIVariant | aPrefValue | |||
) |
Sets a preference stored on the device.
void sbIDevice::cancelRequests | ( | ) |
Cancel all current pending requests
void sbIDevice::syncLibraries | ( | ) |
Call sync() on all libraries attached to this device
void sbIDevice::eject | ( | ) |
Eject device.
readonly attribute AString sbIDevice::name |
A human-readable name identifying the device. Optional.
Definition at line 54 of file sbIDevice.idl.
readonly attribute nsIDPtr sbIDevice::controllerId |
The id of the controller that created the device.
Definition at line 59 of file sbIDevice.idl.
readonly attribute nsIDPtr sbIDevice::id |
The id of the device
Definition at line 64 of file sbIDevice.idl.
readonly attribute boolean sbIDevice::connected |
Whether or not the device is currently connected.
Definition at line 81 of file sbIDevice.idl.
readonly attribute boolean sbIDevice::threaded |
Whether or not the device's events are being processed in additional threads (i.e. off the main UI thread).
Definition at line 87 of file sbIDevice.idl.
readonly attribute sbIDeviceCapabilities sbIDevice::capabilities |
Get the capabilities of the device.
Definition at line 103 of file sbIDevice.idl.
readonly attribute sbIDeviceContent sbIDevice::content |
All the device's content.
Definition at line 108 of file sbIDevice.idl.
readonly attribute nsIPropertyBag2 sbIDevice::parameters |
The parameters with which the device was created
Definition at line 113 of file sbIDevice.idl.
readonly attribute sbIDeviceProperties sbIDevice::properties |
The device's properties.
Definition at line 118 of file sbIDevice.idl.
readonly attribute boolean sbIDevice::isBusy |
Whether the device is currently performing a busy operation, like copying or deleting. This is defined by the device as to what states determine the device is busy.
Definition at line 125 of file sbIDevice.idl.
readonly attribute boolean sbIDevice::canDisconnect |
Whether it is safe to disconnect the device, generally this is when it is not performing a critical operation like copying a file to/from the device. This is also defined by the device as to what states determine the device can be disconnected. Usefull for when the user wants to shutdown the application.
Definition at line 134 of file sbIDevice.idl.
readonly attribute sbIDeviceStatus sbIDevice::currentStatus |
A more detailed state of the device, with information on what item/list it is currently being worked on and includes possible substates for more complicated states.
Definition at line 142 of file sbIDevice.idl.
readonly attribute unsigned long sbIDevice::state |
Whether the device is busy, idle, syncing, mounting, etc.
sbIDeviceEvent::EVENT_DEVICE_MEDIA_WRITE_*
STATE_*
Definition at line 150 of file sbIDevice.idl.