Added in API level 24

MtpEvent


open class MtpEvent
kotlin.Any
   ↳ android.mtp.MtpEvent

This class encapsulates information about a MTP event. This corresponds to the events described in appendix G of the MTP specification.

Summary

Constants
static Int

Event code for CANCEL_TRANSACTION event

static Int

Event code for CAPTURE_COMPLETE event

static Int

Event code for DEVICE_INFO_CHANGED event

static Int

Event code for DEVICE_PROP_CHANGED event

static Int

Event code for DEVICE_RESET event

static Int

Event code for OBJECT_ADDED event

static Int

Event code for OBJECT_INFO_CHANGED event

static Int

Event code for OBJECT_PROP_CHANGED event

static Int

Event code for OBJECT_PROP_DESC_CHANGED event

static Int

Event code for OBJECT_REFERENCES_CHANGED event

static Int

Event code for OBJECT_REMOVED event

static Int

Event code for REQUEST_OBJECT_TRANSFER event

static Int

Event code for STORAGE_INFO_CHANGED event

static Int

Event code for STORE_ADDED event

static Int

Event code for STORE_FULL event

static Int

Event code for STORE_REMOVED event

static Int

Event code for UNDEFINED event

static Int

Event code for UNREPORTED_STATUS event

Public methods
open Int

Obtains devicePropCode event parameter.

open Int

Returns event code of MTP event.

open Int

Obtains objectFormatCode event parameter.

open Int

Obtains objectHandle event parameter.

open Int

Obtains objectPropCode event parameter.

open Int

Obtains the first event parameter.

open Int

Obtains the second event parameter.

open Int

Obtains the third event parameter.

open Int

Obtains storageID event parameter.

open Int

Obtains transactionID event parameter.

Constants

EVENT_CANCEL_TRANSACTION

Added in API level 24
static val EVENT_CANCEL_TRANSACTION: Int

Event code for CANCEL_TRANSACTION event

Value: 16385

EVENT_CAPTURE_COMPLETE

Added in API level 24
static val EVENT_CAPTURE_COMPLETE: Int

Event code for CAPTURE_COMPLETE event

Value: 16397

EVENT_DEVICE_INFO_CHANGED

Added in API level 24
static val EVENT_DEVICE_INFO_CHANGED: Int

Event code for DEVICE_INFO_CHANGED event

Value: 16392

EVENT_DEVICE_PROP_CHANGED

Added in API level 24
static val EVENT_DEVICE_PROP_CHANGED: Int

Event code for DEVICE_PROP_CHANGED event

Value: 16390

EVENT_DEVICE_RESET

Added in API level 24
static val EVENT_DEVICE_RESET: Int

Event code for DEVICE_RESET event

Value: 16395

EVENT_OBJECT_ADDED

Added in API level 24
static val EVENT_OBJECT_ADDED: Int

Event code for OBJECT_ADDED event

Value: 16386

EVENT_OBJECT_INFO_CHANGED

Added in API level 24
static val EVENT_OBJECT_INFO_CHANGED: Int

Event code for OBJECT_INFO_CHANGED event

Value: 16391

EVENT_OBJECT_PROP_CHANGED

Added in API level 24
static val EVENT_OBJECT_PROP_CHANGED: Int

Event code for OBJECT_PROP_CHANGED event

Value: 51201

EVENT_OBJECT_PROP_DESC_CHANGED

Added in API level 24
static val EVENT_OBJECT_PROP_DESC_CHANGED: Int

Event code for OBJECT_PROP_DESC_CHANGED event

Value: 51202

EVENT_OBJECT_REFERENCES_CHANGED

Added in API level 24
static val EVENT_OBJECT_REFERENCES_CHANGED: Int

Event code for OBJECT_REFERENCES_CHANGED event

Value: 51203

EVENT_OBJECT_REMOVED

Added in API level 24
static val EVENT_OBJECT_REMOVED: Int

Event code for OBJECT_REMOVED event

Value: 16387

EVENT_REQUEST_OBJECT_TRANSFER

Added in API level 24
static val EVENT_REQUEST_OBJECT_TRANSFER: Int

Event code for REQUEST_OBJECT_TRANSFER event

Value: 16393

EVENT_STORAGE_INFO_CHANGED

Added in API level 24
static val EVENT_STORAGE_INFO_CHANGED: Int

Event code for STORAGE_INFO_CHANGED event

Value: 16396

EVENT_STORE_ADDED

Added in API level 24
static val EVENT_STORE_ADDED: Int

Event code for STORE_ADDED event

Value: 16388

EVENT_STORE_FULL

Added in API level 24
static val EVENT_STORE_FULL: Int

Event code for STORE_FULL event

Value: 16394

EVENT_STORE_REMOVED

Added in API level 24
static val EVENT_STORE_REMOVED: Int

Event code for STORE_REMOVED event

Value: 16389

EVENT_UNDEFINED

Added in API level 24
static val EVENT_UNDEFINED: Int

Event code for UNDEFINED event

Value: 16384

EVENT_UNREPORTED_STATUS

Added in API level 24
static val EVENT_UNREPORTED_STATUS: Int

Event code for UNREPORTED_STATUS event

Value: 16398

Public methods

getDevicePropCode

Added in API level 24
open fun getDevicePropCode(): Int

Obtains devicePropCode event parameter.

getEventCode

Added in API level 24
open fun getEventCode(): Int

Returns event code of MTP event. See the USB-IF MTP specification for the details of event constants.

Return
Int event code

getObjectFormatCode

Added in API level 24
open fun getObjectFormatCode(): Int

Obtains objectFormatCode event parameter.

getObjectPropCode

Added in API level 24
open fun getObjectPropCode(): Int

Obtains objectPropCode event parameter.

getParameter1

Added in API level 24
open fun getParameter1(): Int

Obtains the first event parameter.

getParameter2

Added in API level 24
open fun getParameter2(): Int

Obtains the second event parameter.

getParameter3

Added in API level 24
open fun getParameter3(): Int

Obtains the third event parameter.

getStorageId

Added in API level 24
open fun getStorageId(): Int

Obtains storageID event parameter.

getTransactionId

Added in API level 24
open fun getTransactionId(): Int

Obtains transactionID event parameter.