android.mtp
Class MtpDevice

java.lang.Object
  extended by android.mtp.MtpDevice

public final class MtpDevice
extends Object


Constructor Summary
MtpDevice(UsbDevice device)
           
 
Method Summary
 void close()
           
 boolean deleteObject(int objectHandle)
           
protected  void finalize()
           
 int getDeviceId()
           
 MtpDeviceInfo getDeviceInfo()
           
 String getDeviceName()
           
 byte[] getObject(int objectHandle, int objectSize)
           
 int[] getObjectHandles(int storageId, int format, int objectHandle)
           
 MtpObjectInfo getObjectInfo(int objectHandle)
           
 long getParent(int objectHandle)
           
 long getStorageId(int objectHandle)
           
 int[] getStorageIds()
           
 MtpStorageInfo getStorageInfo(int storageId)
           
 byte[] getThumbnail(int objectHandle)
           
 boolean importFile(int objectHandle, String destPath)
           
 boolean open(UsbDeviceConnection connection)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MtpDevice

public MtpDevice(UsbDevice device)
Method Detail

open

public boolean open(UsbDeviceConnection connection)

close

public void close()

finalize

protected void finalize()
                 throws Throwable
Overrides:
finalize in class Object
Throws:
Throwable

getDeviceName

public String getDeviceName()

getDeviceId

public int getDeviceId()

toString

public String toString()
Overrides:
toString in class Object

getDeviceInfo

public MtpDeviceInfo getDeviceInfo()

getStorageIds

public int[] getStorageIds()

getObjectHandles

public int[] getObjectHandles(int storageId,
                              int format,
                              int objectHandle)

getObject

public byte[] getObject(int objectHandle,
                        int objectSize)

getThumbnail

public byte[] getThumbnail(int objectHandle)

getStorageInfo

public MtpStorageInfo getStorageInfo(int storageId)

getObjectInfo

public MtpObjectInfo getObjectInfo(int objectHandle)

deleteObject

public boolean deleteObject(int objectHandle)

getParent

public long getParent(int objectHandle)

getStorageId

public long getStorageId(int objectHandle)

importFile

public boolean importFile(int objectHandle,
                          String destPath)


Copyright © 2008-2012. All Rights Reserved.