Lines Matching refs:device

44  * and notifies the application when the MTP device list changes.
57 // so we can inform when the device has been detached.
114 * Called when a new device has been added
116 * @param device the new device that was added
118 public void deviceAdded(MtpDevice device);
121 * Called when a new device has been removed
123 * @param device the device that was removed
125 public void deviceRemoved(MtpDevice device);
132 * @param device the device to test
133 * @return true if the device is a PTP device.
135 static public boolean isCamera(UsbDevice device) {
136 int count = device.getInterfaceCount();
138 UsbInterface intf = device.getInterface(i);
166 * device and return an {@link android.mtp.MtpDevice} for it.
168 * @param device the device to open
169 * @return an MtpDevice for the device.
222 * Retrieves an {@link android.mtp.MtpDevice} object for the USB device
225 * @param deviceName the name of the USB device
235 * Retrieves an {@link android.mtp.MtpDevice} object for the USB device
238 * @param id the ID of the USB device
268 * for the MTP or PTP device with the given USB device name
270 * @param deviceName the name of the USB device
274 MtpDevice device = getDevice(deviceName);
275 if (device == null) {
278 int[] storageIds = device.getStorageIds();
286 MtpStorageInfo info = device.getStorageInfo(storageIds[i]);
298 * the MTP or PTP device with the given USB device name with the given
301 * @param deviceName the name of the USB device
306 MtpDevice device = getDevice(deviceName);
307 if (device == null) {
310 return device.getObjectInfo(objectHandle);
314 * Deletes an object on the MTP or PTP device with the given USB device name.
316 * @param deviceName the name of the USB device
321 MtpDevice device = getDevice(deviceName);
322 if (device == null) {
325 return device.deleteObject(objectHandle);
330 * on the MTP or PTP device with the given USB device name and given storage ID
336 * @param deviceName the name of the USB device
342 MtpDevice device = getDevice(deviceName);
343 if (device == null) {
350 int[] handles = device.getObjectHandles(storageId, 0, objectHandle);
358 MtpObjectInfo info = device.getObjectInfo(handles[i]);
371 * @param deviceName the name of the USB device containing the object
378 MtpDevice device = getDevice(deviceName);
379 if (device == null) {
382 return device.getObject(objectHandle, objectSize);
388 * @param deviceName the name of the USB device containing the object
393 MtpDevice device = getDevice(deviceName);
394 if (device == null) {
397 return device.getThumbnail(objectHandle);
403 * @param deviceName the name of the USB device containing the object
411 MtpDevice device = getDevice(deviceName);
412 if (device == null) {
415 return device.importFile(objectHandle, destPath);