AbstractMassStorageService
On this page
- AbstractMassStorageService ⇐
Abstract
- getAvailableDevices(options) ⇒
Promise.<string>
- getAvailablePartitions(deviceId) ⇒
Promise.<string>
- getStatus(deviceId) ⇒
Promise.<number>
- getTotalSpace(deviceId) ⇒
Promise.<number>
- getFreeSpace(deviceId) ⇒
Promise.<number>
- getPartitionFs(partitionId) ⇒
Promise.<string>
- format(deviceId, fsType) ⇒
Promise.<number>
- _getAvailableDevices(options) ⇒
Promise.<string>
- _getAvailablePartitions(deviceId) ⇒
Promise.<string>
- _getStatus(deviceId) ⇒
Promise.<number>
- _getTotalSpace(deviceId) ⇒
Promise.<number>
- _getFreeSpace(deviceId) ⇒
Promise.<number>
- _getPartitionFs(partitionId) ⇒
Promise.<string>
- _format(deviceId, fsType) ⇒
Promise.<number>
- _onDeviceInsert() ⇒
Promise
- _onDeviceReady() ⇒
Promise
- _onDeviceNotReady() ⇒
Promise
- _onDeviceRemove() ⇒
Promise
- “deviceInsert”
- “deviceReady”
- “deviceNotReady”
- “deviceRemove”
- getAvailableDevices(options) ⇒
AbstractMassStorageService ⇐ Abstract
Kind: global abstract class
Extends: Abstract
Service:
- AbstractMassStorageService ⇐
Abstract
- .getAvailableDevices(options) ⇒
Promise.<string>
- .getAvailablePartitions(deviceId) ⇒
Promise.<string>
- .getStatus(deviceId) ⇒
Promise.<number>
- .getTotalSpace(deviceId) ⇒
Promise.<number>
- .getFreeSpace(deviceId) ⇒
Promise.<number>
- .getPartitionFs(partitionId) ⇒
Promise.<string>
- .format(deviceId, fsType) ⇒
Promise.<number>
- ._getAvailableDevices(options) ⇒
Promise.<string>
- ._getAvailablePartitions(deviceId) ⇒
Promise.<string>
- ._getStatus(deviceId) ⇒
Promise.<number>
- ._getTotalSpace(deviceId) ⇒
Promise.<number>
- ._getFreeSpace(deviceId) ⇒
Promise.<number>
- ._getPartitionFs(partitionId) ⇒
Promise.<string>
- ._format(deviceId, fsType) ⇒
Promise.<number>
- ._onDeviceInsert() ⇒
Promise
- ._onDeviceReady() ⇒
Promise
- ._onDeviceNotReady() ⇒
Promise
- ._onDeviceRemove() ⇒
Promise
- “deviceInsert”
- “deviceReady”
- “deviceNotReady”
- “deviceRemove”
- .getAvailableDevices(options) ⇒
getAvailableDevices(options) ⇒ Promise.<string>
Get all available devices
Kind: instance method of AbstractMassStorageService
Param | Type | Description |
---|---|---|
options | Object | additional options |
getAvailablePartitions(deviceId) ⇒ Promise.<string>
Get all partitions of a device, if not exist return an empty array.
Kind: instance method of AbstractMassStorageService
Param | Type | Description |
---|---|---|
deviceId | string | id of device |
getStatus(deviceId) ⇒ Promise.<number>
Get device status, STATE_READY | STATE_REMOVED
Kind: instance method of AbstractMassStorageService
Param | Type | Description |
---|---|---|
deviceId | string | id of device |
getTotalSpace(deviceId) ⇒ Promise.<number>
The total capacity (in megabytes) of the storage device.
Kind: instance method of AbstractMassStorageService
Param | Type | Description |
---|---|---|
deviceId | string | id of device |
getFreeSpace(deviceId) ⇒ Promise.<number>
The space (in megabytes) available on the storage device
Kind: instance method of AbstractMassStorageService
Param | Type | Description |
---|---|---|
deviceId | string | id of device |
getPartitionFs(partitionId) ⇒ Promise.<string>
Get partition file system type
Kind: instance method of AbstractMassStorageService
Param | Type | Description |
---|---|---|
partitionId | string | id of partition |
format(deviceId, fsType) ⇒ Promise.<number>
Format the mass storage
Kind: instance method of AbstractMassStorageService
Param | Type | Description |
---|---|---|
deviceId | string | id of device |
fsType | string |
_getAvailableDevices(options) ⇒ Promise.<string>
Kind: instance abstract method of AbstractMassStorageService
Access: protected
Param | Type | Description |
---|---|---|
options | Object | additional options |
_getAvailablePartitions(deviceId) ⇒ Promise.<string>
Kind: instance abstract method of AbstractMassStorageService
Access: protected
Param | Type | Description |
---|---|---|
deviceId | string | id of device |
_getStatus(deviceId) ⇒ Promise.<number>
Kind: instance abstract method of AbstractMassStorageService
Access: protected
Param | Type | Description |
---|---|---|
deviceId | string | id of device |
_getTotalSpace(deviceId) ⇒ Promise.<number>
Kind: instance abstract method of AbstractMassStorageService
Access: protected
Param | Type | Description |
---|---|---|
deviceId | string | id of device |
_getFreeSpace(deviceId) ⇒ Promise.<number>
Kind: instance abstract method of AbstractMassStorageService
Access: protected
Param | Type | Description |
---|---|---|
deviceId | string | id of device |
_getPartitionFs(partitionId) ⇒ Promise.<string>
Kind: instance abstract method of AbstractMassStorageService
Access: protected
Param | Type | Description |
---|---|---|
partitionId | string | id of device |
_format(deviceId, fsType) ⇒ Promise.<number>
Kind: instance abstract method of AbstractMassStorageService
Access: protected
Param | Type | Description |
---|---|---|
deviceId | string | id of device |
fsType | string |
_onDeviceInsert() ⇒ Promise
Fired when a device was inserted
Kind: instance method of AbstractMassStorageService
Access: protected
_onDeviceReady() ⇒ Promise
Fired when a device was ready to use
Kind: instance method of AbstractMassStorageService
Access: protected
_onDeviceNotReady() ⇒ Promise
Fired when a device was not ready to use
Kind: instance method of AbstractMassStorageService
Access: protected
_onDeviceRemove() ⇒ Promise
Fired when a device was removed
Kind: instance method of AbstractMassStorageService
Access: protected
“deviceInsert”
Fired when a device was inserted
Kind: event emitted by AbstractMassStorageService
“deviceReady”
Fired when a device was ready to use
Kind: event emitted by AbstractMassStorageService
“deviceNotReady”
Fired when a device was not ready to use
Kind: event emitted by AbstractMassStorageService
“deviceRemove”
Fired when a device was removed
Kind: event emitted by AbstractMassStorageService