import typing

import android.hardware.usb
import android.os
import java
import java.chaquopy
import java.lang

class MtpConstants(java.lang.Object):
    ASSOCIATION_TYPE_GENERIC_FOLDER: typing.ClassVar[int] = ...
    FORMAT_3GP_CONTAINER: typing.ClassVar[int] = ...
    FORMAT_AAC: typing.ClassVar[int] = ...
    FORMAT_ABSTRACT_AUDIO_ALBUM: typing.ClassVar[int] = ...
    FORMAT_ABSTRACT_AUDIO_PLAYLIST: typing.ClassVar[int] = ...
    FORMAT_ABSTRACT_AV_PLAYLIST: typing.ClassVar[int] = ...
    FORMAT_ABSTRACT_DOCUMENT: typing.ClassVar[int] = ...
    FORMAT_ABSTRACT_IMAGE_ALBUM: typing.ClassVar[int] = ...
    FORMAT_ABSTRACT_MEDIACAST: typing.ClassVar[int] = ...
    FORMAT_ABSTRACT_MULTIMEDIA_ALBUM: typing.ClassVar[int] = ...
    FORMAT_ABSTRACT_VIDEO_ALBUM: typing.ClassVar[int] = ...
    FORMAT_ABSTRACT_VIDEO_PLAYLIST: typing.ClassVar[int] = ...
    FORMAT_AIFF: typing.ClassVar[int] = ...
    FORMAT_ASF: typing.ClassVar[int] = ...
    FORMAT_ASSOCIATION: typing.ClassVar[int] = ...
    FORMAT_ASX_PLAYLIST: typing.ClassVar[int] = ...
    FORMAT_AUDIBLE: typing.ClassVar[int] = ...
    FORMAT_AVI: typing.ClassVar[int] = ...
    FORMAT_BMP: typing.ClassVar[int] = ...
    FORMAT_DEFINED: typing.ClassVar[int] = ...
    FORMAT_DNG: typing.ClassVar[int] = ...
    FORMAT_DPOF: typing.ClassVar[int] = ...
    FORMAT_EXECUTABLE: typing.ClassVar[int] = ...
    FORMAT_EXIF_JPEG: typing.ClassVar[int] = ...
    FORMAT_FLAC: typing.ClassVar[int] = ...
    FORMAT_GIF: typing.ClassVar[int] = ...
    FORMAT_HTML: typing.ClassVar[int] = ...
    FORMAT_JFIF: typing.ClassVar[int] = ...
    FORMAT_JP2: typing.ClassVar[int] = ...
    FORMAT_JPX: typing.ClassVar[int] = ...
    FORMAT_M3U_PLAYLIST: typing.ClassVar[int] = ...
    FORMAT_MP2: typing.ClassVar[int] = ...
    FORMAT_MP3: typing.ClassVar[int] = ...
    FORMAT_MP4_CONTAINER: typing.ClassVar[int] = ...
    FORMAT_MPEG: typing.ClassVar[int] = ...
    FORMAT_MPL_PLAYLIST: typing.ClassVar[int] = ...
    FORMAT_MS_EXCEL_SPREADSHEET: typing.ClassVar[int] = ...
    FORMAT_MS_POWERPOINT_PRESENTATION: typing.ClassVar[int] = ...
    FORMAT_MS_WORD_DOCUMENT: typing.ClassVar[int] = ...
    FORMAT_OGG: typing.ClassVar[int] = ...
    FORMAT_PICT: typing.ClassVar[int] = ...
    FORMAT_PLS_PLAYLIST: typing.ClassVar[int] = ...
    FORMAT_PNG: typing.ClassVar[int] = ...
    FORMAT_SCRIPT: typing.ClassVar[int] = ...
    FORMAT_TEXT: typing.ClassVar[int] = ...
    FORMAT_TIFF: typing.ClassVar[int] = ...
    FORMAT_TIFF_EP: typing.ClassVar[int] = ...
    FORMAT_UNDEFINED: typing.ClassVar[int] = ...
    FORMAT_UNDEFINED_AUDIO: typing.ClassVar[int] = ...
    FORMAT_UNDEFINED_COLLECTION: typing.ClassVar[int] = ...
    FORMAT_UNDEFINED_DOCUMENT: typing.ClassVar[int] = ...
    FORMAT_UNDEFINED_FIRMWARE: typing.ClassVar[int] = ...
    FORMAT_UNDEFINED_VIDEO: typing.ClassVar[int] = ...
    FORMAT_WAV: typing.ClassVar[int] = ...
    FORMAT_WINDOWS_IMAGE_FORMAT: typing.ClassVar[int] = ...
    FORMAT_WMA: typing.ClassVar[int] = ...
    FORMAT_WMV: typing.ClassVar[int] = ...
    FORMAT_WPL_PLAYLIST: typing.ClassVar[int] = ...
    FORMAT_XML_DOCUMENT: typing.ClassVar[int] = ...
    OPERATION_CLOSE_SESSION: typing.ClassVar[int] = ...
    OPERATION_COPY_OBJECT: typing.ClassVar[int] = ...
    OPERATION_DELETE_OBJECT: typing.ClassVar[int] = ...
    OPERATION_FORMAT_STORE: typing.ClassVar[int] = ...
    OPERATION_GET_DEVICE_INFO: typing.ClassVar[int] = ...
    OPERATION_GET_DEVICE_PROP_DESC: typing.ClassVar[int] = ...
    OPERATION_GET_DEVICE_PROP_VALUE: typing.ClassVar[int] = ...
    OPERATION_GET_NUM_OBJECTS: typing.ClassVar[int] = ...
    OPERATION_GET_OBJECT: typing.ClassVar[int] = ...
    OPERATION_GET_OBJECT_HANDLES: typing.ClassVar[int] = ...
    OPERATION_GET_OBJECT_INFO: typing.ClassVar[int] = ...
    OPERATION_GET_OBJECT_PROPS_SUPPORTED: typing.ClassVar[int] = ...
    OPERATION_GET_OBJECT_PROP_DESC: typing.ClassVar[int] = ...
    OPERATION_GET_OBJECT_PROP_VALUE: typing.ClassVar[int] = ...
    OPERATION_GET_OBJECT_REFERENCES: typing.ClassVar[int] = ...
    OPERATION_GET_PARTIAL_OBJECT: typing.ClassVar[int] = ...
    OPERATION_GET_PARTIAL_OBJECT_64: typing.ClassVar[int] = ...
    OPERATION_GET_STORAGE_INFO: typing.ClassVar[int] = ...
    OPERATION_GET_STORAGE_I_DS: typing.ClassVar[int] = ...
    OPERATION_GET_THUMB: typing.ClassVar[int] = ...
    OPERATION_INITIATE_CAPTURE: typing.ClassVar[int] = ...
    OPERATION_INITIATE_OPEN_CAPTURE: typing.ClassVar[int] = ...
    OPERATION_MOVE_OBJECT: typing.ClassVar[int] = ...
    OPERATION_OPEN_SESSION: typing.ClassVar[int] = ...
    OPERATION_POWER_DOWN: typing.ClassVar[int] = ...
    OPERATION_RESET_DEVICE: typing.ClassVar[int] = ...
    OPERATION_RESET_DEVICE_PROP_VALUE: typing.ClassVar[int] = ...
    OPERATION_SELF_TEST: typing.ClassVar[int] = ...
    OPERATION_SEND_OBJECT: typing.ClassVar[int] = ...
    OPERATION_SEND_OBJECT_INFO: typing.ClassVar[int] = ...
    OPERATION_SET_DEVICE_PROP_VALUE: typing.ClassVar[int] = ...
    OPERATION_SET_OBJECT_PROP_VALUE: typing.ClassVar[int] = ...
    OPERATION_SET_OBJECT_PROTECTION: typing.ClassVar[int] = ...
    OPERATION_SET_OBJECT_REFERENCES: typing.ClassVar[int] = ...
    OPERATION_SKIP: typing.ClassVar[int] = ...
    OPERATION_TERMINATE_OPEN_CAPTURE: typing.ClassVar[int] = ...
    PROTECTION_STATUS_NONE: typing.ClassVar[int] = ...
    PROTECTION_STATUS_NON_TRANSFERABLE_DATA: typing.ClassVar[int] = ...
    PROTECTION_STATUS_READ_ONLY: typing.ClassVar[int] = ...
    PROTECTION_STATUS_READ_ONLY_DATA: typing.ClassVar[int] = ...
    def __init__(self) -> None: ...
    @staticmethod
    def isAbstractObject(format: int | java.jint | java.lang.Integer, /) -> bool: ...

class MtpDevice(java.lang.Object):
    def __init__(self, device: android.hardware.usb.UsbDevice, /) -> None: ...
    def close(self) -> None: ...
    def deleteObject(self, objectHandle: int | java.jint | java.lang.Integer, /) -> bool: ...
    def finalize(self) -> None: ...
    def getDeviceId(self) -> int: ...
    def getDeviceInfo(self) -> MtpDeviceInfo | None: ...
    def getDeviceName(self) -> str: ...
    def getObject(self, objectHandle: int | java.jint | java.lang.Integer, objectSize: int | java.jint | java.lang.Integer, /) -> java.chaquopy.JavaArrayJByte | None: ...
    def getObjectHandles(self, storageId: int | java.jint | java.lang.Integer, format: int | java.jint | java.lang.Integer, objectHandle: int | java.jint | java.lang.Integer, /) -> java.chaquopy.JavaArrayJInt | None: ...
    def getObjectInfo(self, objectHandle: int | java.jint | java.lang.Integer, /) -> MtpObjectInfo | None: ...
    def getParent(self, objectHandle: int | java.jint | java.lang.Integer, /) -> int: ...
    def getPartialObject(self, objectHandle: int | java.jint | java.lang.Integer, offset: int | java.jlong | java.lang.Long, size: int | java.jlong | java.lang.Long, buffer: java.chaquopy.JavaArrayJByte, /) -> int: ...
    def getPartialObject64(self, objectHandle: int | java.jint | java.lang.Integer, offset: int | java.jlong | java.lang.Long, size: int | java.jlong | java.lang.Long, buffer: java.chaquopy.JavaArrayJByte, /) -> int: ...
    def getStorageId(self, objectHandle: int | java.jint | java.lang.Integer, /) -> int: ...
    def getStorageIds(self) -> java.chaquopy.JavaArrayJInt | None: ...
    def getStorageInfo(self, storageId: int | java.jint | java.lang.Integer, /) -> MtpStorageInfo | None: ...
    def getThumbnail(self, objectHandle: int | java.jint | java.lang.Integer, /) -> java.chaquopy.JavaArrayJByte | None: ...
    @typing.overload
    def importFile(self, objectHandle: int | java.jint | java.lang.Integer, descriptor: android.os.ParcelFileDescriptor, /) -> bool: ...
    @typing.overload
    def importFile(self, objectHandle: int | java.jint | java.lang.Integer, destPath: str | java.lang.String, /) -> bool: ...
    def open(self, connection: android.hardware.usb.UsbDeviceConnection, /) -> bool: ...
    def readEvent(self, signal: android.os.CancellationSignal, /) -> MtpEvent: ...
    def sendObject(self, objectHandle: int | java.jint | java.lang.Integer, size: int | java.jlong | java.lang.Long, descriptor: android.os.ParcelFileDescriptor, /) -> bool: ...
    def sendObjectInfo(self, info: MtpObjectInfo, /) -> MtpObjectInfo | None: ...
    def toString(self) -> str: ...

class MtpDeviceInfo(java.lang.Object):
    def getEventsSupported(self) -> java.chaquopy.JavaArrayJInt | None: ...
    def getManufacturer(self) -> str: ...
    def getModel(self) -> str: ...
    def getOperationsSupported(self) -> java.chaquopy.JavaArrayJInt | None: ...
    def getSerialNumber(self) -> str: ...
    def getVersion(self) -> str: ...
    def isEventSupported(self, code: int | java.jint | java.lang.Integer, /) -> bool: ...
    def isOperationSupported(self, code: int | java.jint | java.lang.Integer, /) -> bool: ...

class MtpEvent(java.lang.Object):
    EVENT_CANCEL_TRANSACTION: typing.ClassVar[int] = ...
    EVENT_CAPTURE_COMPLETE: typing.ClassVar[int] = ...
    EVENT_DEVICE_INFO_CHANGED: typing.ClassVar[int] = ...
    EVENT_DEVICE_PROP_CHANGED: typing.ClassVar[int] = ...
    EVENT_DEVICE_RESET: typing.ClassVar[int] = ...
    EVENT_OBJECT_ADDED: typing.ClassVar[int] = ...
    EVENT_OBJECT_INFO_CHANGED: typing.ClassVar[int] = ...
    EVENT_OBJECT_PROP_CHANGED: typing.ClassVar[int] = ...
    EVENT_OBJECT_PROP_DESC_CHANGED: typing.ClassVar[int] = ...
    EVENT_OBJECT_REFERENCES_CHANGED: typing.ClassVar[int] = ...
    EVENT_OBJECT_REMOVED: typing.ClassVar[int] = ...
    EVENT_REQUEST_OBJECT_TRANSFER: typing.ClassVar[int] = ...
    EVENT_STORAGE_INFO_CHANGED: typing.ClassVar[int] = ...
    EVENT_STORE_ADDED: typing.ClassVar[int] = ...
    EVENT_STORE_FULL: typing.ClassVar[int] = ...
    EVENT_STORE_REMOVED: typing.ClassVar[int] = ...
    EVENT_UNDEFINED: typing.ClassVar[int] = ...
    EVENT_UNREPORTED_STATUS: typing.ClassVar[int] = ...
    def getDevicePropCode(self) -> int: ...
    def getEventCode(self) -> int: ...
    def getObjectFormatCode(self) -> int: ...
    def getObjectHandle(self) -> int: ...
    def getObjectPropCode(self) -> int: ...
    def getParameter1(self) -> int: ...
    def getParameter2(self) -> int: ...
    def getParameter3(self) -> int: ...
    def getStorageId(self) -> int: ...
    def getTransactionId(self) -> int: ...

class MtpObjectInfo(java.lang.Object):
    def getAssociationDesc(self) -> int: ...
    def getAssociationType(self) -> int: ...
    def getCompressedSize(self) -> int: ...
    def getCompressedSizeLong(self) -> int: ...
    def getDateCreated(self) -> int: ...
    def getDateModified(self) -> int: ...
    def getFormat(self) -> int: ...
    def getImagePixDepth(self) -> int: ...
    def getImagePixDepthLong(self) -> int: ...
    def getImagePixHeight(self) -> int: ...
    def getImagePixHeightLong(self) -> int: ...
    def getImagePixWidth(self) -> int: ...
    def getImagePixWidthLong(self) -> int: ...
    def getKeywords(self) -> str: ...
    def getName(self) -> str: ...
    def getObjectHandle(self) -> int: ...
    def getParent(self) -> int: ...
    def getProtectionStatus(self) -> int: ...
    def getSequenceNumber(self) -> int: ...
    def getSequenceNumberLong(self) -> int: ...
    def getStorageId(self) -> int: ...
    def getThumbCompressedSize(self) -> int: ...
    def getThumbCompressedSizeLong(self) -> int: ...
    def getThumbFormat(self) -> int: ...
    def getThumbPixHeight(self) -> int: ...
    def getThumbPixHeightLong(self) -> int: ...
    def getThumbPixWidth(self) -> int: ...
    def getThumbPixWidthLong(self) -> int: ...

    class Builder(java.lang.Object):
        @typing.overload
        def __init__(self) -> None: ...
        @typing.overload
        def __init__(self, objectInfo: MtpObjectInfo, /) -> None: ...
        def build(self) -> MtpObjectInfo: ...
        def setAssociationDesc(self, value: int | java.jint | java.lang.Integer, /) -> MtpObjectInfo.Builder: ...
        def setAssociationType(self, value: int | java.jint | java.lang.Integer, /) -> MtpObjectInfo.Builder: ...
        def setCompressedSize(self, value: int | java.jlong | java.lang.Long, /) -> MtpObjectInfo.Builder: ...
        def setDateCreated(self, value: int | java.jlong | java.lang.Long, /) -> MtpObjectInfo.Builder: ...
        def setDateModified(self, value: int | java.jlong | java.lang.Long, /) -> MtpObjectInfo.Builder: ...
        def setFormat(self, value: int | java.jint | java.lang.Integer, /) -> MtpObjectInfo.Builder: ...
        def setImagePixDepth(self, value: int | java.jlong | java.lang.Long, /) -> MtpObjectInfo.Builder: ...
        def setImagePixHeight(self, value: int | java.jlong | java.lang.Long, /) -> MtpObjectInfo.Builder: ...
        def setImagePixWidth(self, value: int | java.jlong | java.lang.Long, /) -> MtpObjectInfo.Builder: ...
        def setKeywords(self, value: str | java.lang.String, /) -> MtpObjectInfo.Builder: ...
        def setName(self, value: str | java.lang.String, /) -> MtpObjectInfo.Builder: ...
        def setObjectHandle(self, value: int | java.jint | java.lang.Integer, /) -> MtpObjectInfo.Builder: ...
        def setParent(self, value: int | java.jint | java.lang.Integer, /) -> MtpObjectInfo.Builder: ...
        def setProtectionStatus(self, value: int | java.jint | java.lang.Integer, /) -> MtpObjectInfo.Builder: ...
        def setSequenceNumber(self, value: int | java.jlong | java.lang.Long, /) -> MtpObjectInfo.Builder: ...
        def setStorageId(self, value: int | java.jint | java.lang.Integer, /) -> MtpObjectInfo.Builder: ...
        def setThumbCompressedSize(self, value: int | java.jlong | java.lang.Long, /) -> MtpObjectInfo.Builder: ...
        def setThumbFormat(self, value: int | java.jint | java.lang.Integer, /) -> MtpObjectInfo.Builder: ...
        def setThumbPixHeight(self, value: int | java.jlong | java.lang.Long, /) -> MtpObjectInfo.Builder: ...
        def setThumbPixWidth(self, value: int | java.jlong | java.lang.Long, /) -> MtpObjectInfo.Builder: ...

class MtpStorageInfo(java.lang.Object):
    def getDescription(self) -> str: ...
    def getFreeSpace(self) -> int: ...
    def getMaxCapacity(self) -> int: ...
    def getStorageId(self) -> int: ...
    def getVolumeIdentifier(self) -> str: ...
