|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IUsbStorageManagerService
The USB Storage Manager Service provides tools for management of USB Mass Storage devices.
Field Summary | |
---|---|
static java.lang.String |
SERVICE_NAME
Reports the class name representing this interface. |
static java.lang.String |
USB_STORAGE_ATTACHED
|
static java.lang.String |
USB_STORAGE_DETACHED
|
Method Summary | |
---|---|
boolean |
areDevicesPresent()
This method returns whether or not there are any devices currently attached. |
java.lang.String |
getDeviceNode(java.lang.String usbPortNumber)
This method returns the device node that has been assigned to the USB Mass Storage device attached to a specified USB port. |
java.lang.String[] |
getDeviceUsbPorts()
Returns an array of Strings that represent the USB port names of the connected devices. |
java.lang.String[] |
getPartitions(java.lang.String deviceNode)
Returns a list of Strings representing the partitions on the storage device, null if no partitions exits. |
boolean |
mountDevice(java.lang.String deviceNode,
java.lang.String mountPoint,
java.lang.String type)
This method mounts a specified USB Mass Storage device to a specified mount point. |
void |
registerListener(UsbStorageListener listener)
This method registers an USB Storage Listener to be notified when a device has been attached or detached |
boolean |
unmountDevice(java.lang.String mountPoint)
This method unmounts a specified USB Mass Storage device. |
void |
unregisterListener(UsbStorageListener listener)
This method unregisters an USB Storage Listener |
Field Detail |
---|
static final java.lang.String SERVICE_NAME
static final java.lang.String USB_STORAGE_ATTACHED
static final java.lang.String USB_STORAGE_DETACHED
Method Detail |
---|
boolean areDevicesPresent()
java.lang.String[] getDeviceUsbPorts()
java.lang.String getDeviceNode(java.lang.String usbPortNumber)
usbPortNumber
- A String representing the USB port that the device is plugged into.
boolean mountDevice(java.lang.String deviceNode, java.lang.String mountPoint, java.lang.String type)
deviceNode
- A String representing the USB device node assigned to the USB device.mountPoint
- A String representing the mount point for the USB device to be mounted to.type
- The filesystem type to mount the device as
boolean unmountDevice(java.lang.String mountPoint)
mountPoint
- A String representing the mount point for the USB device to be unmounted.
void registerListener(UsbStorageListener listener)
listener
- A class implementing the UsbStorageListener interfacevoid unregisterListener(UsbStorageListener listener)
listener
- A class implementing the UsbStorageListener interfacejava.lang.String[] getPartitions(java.lang.String deviceNode)
deviceNode
- A String representing the USB device node assigned to the USB device.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |