import typing

import android.app
import android.bluetooth
import android.content
import android.content.pm
import android.graphics
import android.hardware
import android.hardware.usb
import android.os
import android.util
import android.view
import android.view.accessibility
import android.view.inputmethod
import java
import java.chaquopy
import java.lang
import java.util
import java.util.concurrent

class AccessibilityButtonController(java.lang.Object):
    def isAccessibilityButtonAvailable(self) -> bool: ...
    @typing.overload
    def registerAccessibilityButtonCallback(self, callback: AccessibilityButtonController.AccessibilityButtonCallback, /) -> None: ...
    @typing.overload
    def registerAccessibilityButtonCallback(self, callback: AccessibilityButtonController.AccessibilityButtonCallback, handler: android.os.Handler, /) -> None: ...
    def unregisterAccessibilityButtonCallback(self, callback: AccessibilityButtonController.AccessibilityButtonCallback, /) -> None: ...

    class AccessibilityButtonCallback(java.lang.Object):
        def __init__(self) -> None: ...
        def onAvailabilityChanged(self, controller: AccessibilityButtonController, available: bool | java.jboolean | java.lang.Boolean, /) -> None: ...
        def onClicked(self, controller: AccessibilityButtonController, /) -> None: ...

class AccessibilityGestureEvent(android.os.Parcelable):
    CREATOR: typing.ClassVar[android.os.Parcelable.Creator[AccessibilityGestureEvent]] = ...
    def __init__(self, gestureId: int | java.jint | java.lang.Integer, displayId: int | java.jint | java.lang.Integer, motionEvents: java.util.List[android.view.MotionEvent], /) -> None: ...
    def describeContents(self) -> int: ...
    @staticmethod
    def gestureIdToString(id: int | java.jint | java.lang.Integer, /) -> str: ...
    def getDisplayId(self) -> int: ...
    def getGestureId(self) -> int: ...
    def getMotionEvents(self) -> java.util.List[android.view.MotionEvent]: ...
    def toString(self) -> str: ...
    def writeToParcel(self, parcel: android.os.Parcel, flags: int | java.jint | java.lang.Integer, /) -> None: ...

class AccessibilityService(android.app.Service):
    ERROR_TAKE_SCREENSHOT_INTERNAL_ERROR: typing.ClassVar[int] = ...
    ERROR_TAKE_SCREENSHOT_INTERVAL_TIME_SHORT: typing.ClassVar[int] = ...
    ERROR_TAKE_SCREENSHOT_INVALID_DISPLAY: typing.ClassVar[int] = ...
    ERROR_TAKE_SCREENSHOT_INVALID_WINDOW: typing.ClassVar[int] = ...
    ERROR_TAKE_SCREENSHOT_NO_ACCESSIBILITY_ACCESS: typing.ClassVar[int] = ...
    ERROR_TAKE_SCREENSHOT_SECURE_WINDOW: typing.ClassVar[int] = ...
    GESTURE_2_FINGER_DOUBLE_TAP: typing.ClassVar[int] = ...
    GESTURE_2_FINGER_DOUBLE_TAP_AND_HOLD: typing.ClassVar[int] = ...
    GESTURE_2_FINGER_SINGLE_TAP: typing.ClassVar[int] = ...
    GESTURE_2_FINGER_SWIPE_DOWN: typing.ClassVar[int] = ...
    GESTURE_2_FINGER_SWIPE_LEFT: typing.ClassVar[int] = ...
    GESTURE_2_FINGER_SWIPE_RIGHT: typing.ClassVar[int] = ...
    GESTURE_2_FINGER_SWIPE_UP: typing.ClassVar[int] = ...
    GESTURE_2_FINGER_TRIPLE_TAP: typing.ClassVar[int] = ...
    GESTURE_2_FINGER_TRIPLE_TAP_AND_HOLD: typing.ClassVar[int] = ...
    GESTURE_3_FINGER_DOUBLE_TAP: typing.ClassVar[int] = ...
    GESTURE_3_FINGER_DOUBLE_TAP_AND_HOLD: typing.ClassVar[int] = ...
    GESTURE_3_FINGER_SINGLE_TAP: typing.ClassVar[int] = ...
    GESTURE_3_FINGER_SINGLE_TAP_AND_HOLD: typing.ClassVar[int] = ...
    GESTURE_3_FINGER_SWIPE_DOWN: typing.ClassVar[int] = ...
    GESTURE_3_FINGER_SWIPE_LEFT: typing.ClassVar[int] = ...
    GESTURE_3_FINGER_SWIPE_RIGHT: typing.ClassVar[int] = ...
    GESTURE_3_FINGER_SWIPE_UP: typing.ClassVar[int] = ...
    GESTURE_3_FINGER_TRIPLE_TAP: typing.ClassVar[int] = ...
    GESTURE_3_FINGER_TRIPLE_TAP_AND_HOLD: typing.ClassVar[int] = ...
    GESTURE_4_FINGER_DOUBLE_TAP: typing.ClassVar[int] = ...
    GESTURE_4_FINGER_DOUBLE_TAP_AND_HOLD: typing.ClassVar[int] = ...
    GESTURE_4_FINGER_SINGLE_TAP: typing.ClassVar[int] = ...
    GESTURE_4_FINGER_SWIPE_DOWN: typing.ClassVar[int] = ...
    GESTURE_4_FINGER_SWIPE_LEFT: typing.ClassVar[int] = ...
    GESTURE_4_FINGER_SWIPE_RIGHT: typing.ClassVar[int] = ...
    GESTURE_4_FINGER_SWIPE_UP: typing.ClassVar[int] = ...
    GESTURE_4_FINGER_TRIPLE_TAP: typing.ClassVar[int] = ...
    GESTURE_DOUBLE_TAP: typing.ClassVar[int] = ...
    GESTURE_DOUBLE_TAP_AND_HOLD: typing.ClassVar[int] = ...
    GESTURE_SWIPE_DOWN: typing.ClassVar[int] = ...
    GESTURE_SWIPE_DOWN_AND_LEFT: typing.ClassVar[int] = ...
    GESTURE_SWIPE_DOWN_AND_RIGHT: typing.ClassVar[int] = ...
    GESTURE_SWIPE_DOWN_AND_UP: typing.ClassVar[int] = ...
    GESTURE_SWIPE_LEFT: typing.ClassVar[int] = ...
    GESTURE_SWIPE_LEFT_AND_DOWN: typing.ClassVar[int] = ...
    GESTURE_SWIPE_LEFT_AND_RIGHT: typing.ClassVar[int] = ...
    GESTURE_SWIPE_LEFT_AND_UP: typing.ClassVar[int] = ...
    GESTURE_SWIPE_RIGHT: typing.ClassVar[int] = ...
    GESTURE_SWIPE_RIGHT_AND_DOWN: typing.ClassVar[int] = ...
    GESTURE_SWIPE_RIGHT_AND_LEFT: typing.ClassVar[int] = ...
    GESTURE_SWIPE_RIGHT_AND_UP: typing.ClassVar[int] = ...
    GESTURE_SWIPE_UP: typing.ClassVar[int] = ...
    GESTURE_SWIPE_UP_AND_DOWN: typing.ClassVar[int] = ...
    GESTURE_SWIPE_UP_AND_LEFT: typing.ClassVar[int] = ...
    GESTURE_SWIPE_UP_AND_RIGHT: typing.ClassVar[int] = ...
    GESTURE_UNKNOWN: typing.ClassVar[int] = ...
    GLOBAL_ACTION_ACCESSIBILITY_ALL_APPS: typing.ClassVar[int] = ...
    GLOBAL_ACTION_ACCESSIBILITY_BUTTON: typing.ClassVar[int] = ...
    GLOBAL_ACTION_ACCESSIBILITY_BUTTON_CHOOSER: typing.ClassVar[int] = ...
    GLOBAL_ACTION_ACCESSIBILITY_SHORTCUT: typing.ClassVar[int] = ...
    GLOBAL_ACTION_BACK: typing.ClassVar[int] = ...
    GLOBAL_ACTION_DISMISS_NOTIFICATION_SHADE: typing.ClassVar[int] = ...
    GLOBAL_ACTION_DPAD_CENTER: typing.ClassVar[int] = ...
    GLOBAL_ACTION_DPAD_DOWN: typing.ClassVar[int] = ...
    GLOBAL_ACTION_DPAD_LEFT: typing.ClassVar[int] = ...
    GLOBAL_ACTION_DPAD_RIGHT: typing.ClassVar[int] = ...
    GLOBAL_ACTION_DPAD_UP: typing.ClassVar[int] = ...
    GLOBAL_ACTION_HOME: typing.ClassVar[int] = ...
    GLOBAL_ACTION_KEYCODE_HEADSETHOOK: typing.ClassVar[int] = ...
    GLOBAL_ACTION_LOCK_SCREEN: typing.ClassVar[int] = ...
    GLOBAL_ACTION_MEDIA_PLAY_PAUSE: typing.ClassVar[int] = ...
    GLOBAL_ACTION_MENU: typing.ClassVar[int] = ...
    GLOBAL_ACTION_NOTIFICATIONS: typing.ClassVar[int] = ...
    GLOBAL_ACTION_POWER_DIALOG: typing.ClassVar[int] = ...
    GLOBAL_ACTION_QUICK_SETTINGS: typing.ClassVar[int] = ...
    GLOBAL_ACTION_RECENTS: typing.ClassVar[int] = ...
    GLOBAL_ACTION_TAKE_SCREENSHOT: typing.ClassVar[int] = ...
    GLOBAL_ACTION_TOGGLE_SPLIT_SCREEN: typing.ClassVar[int] = ...
    SERVICE_INTERFACE: typing.ClassVar[str] = ...
    SERVICE_META_DATA: typing.ClassVar[str] = ...
    SHOW_MODE_AUTO: typing.ClassVar[int] = ...
    SHOW_MODE_HIDDEN: typing.ClassVar[int] = ...
    SHOW_MODE_IGNORE_HARD_KEYBOARD: typing.ClassVar[int] = ...
    def __init__(self) -> None: ...
    def attachAccessibilityOverlayToDisplay(self, displayId: int | java.jint | java.lang.Integer, sc: android.view.SurfaceControl, /) -> None: ...
    def attachAccessibilityOverlayToWindow(self, accessibilityWindowId: int | java.jint | java.lang.Integer, sc: android.view.SurfaceControl, /) -> None: ...
    def clearCache(self) -> bool: ...
    def clearCachedSubtree(self, node: android.view.accessibility.AccessibilityNodeInfo, /) -> bool: ...
    def createDisplayContext(self, display: android.view.Display, /) -> android.content.Context: ...
    @typing.overload
    def createWindowContext(self, type: int | java.jint | java.lang.Integer, options: android.os.Bundle, /) -> android.content.Context | None: ...
    @typing.overload
    def createWindowContext(self, display: android.view.Display, type: int | java.jint | java.lang.Integer, options: android.os.Bundle, /) -> android.content.Context | None: ...
    def disableSelf(self) -> None: ...
    def dispatchGesture(self, gesture: GestureDescription, callback: AccessibilityService.GestureResultCallback, handler: android.os.Handler, /) -> bool: ...
    def findFocus(self, focus: int | java.jint | java.lang.Integer, /) -> android.view.accessibility.AccessibilityNodeInfo | None: ...
    @typing.overload
    def getAccessibilityButtonController(self) -> AccessibilityButtonController: ...
    @typing.overload
    def getAccessibilityButtonController(self, displayId: int | java.jint | java.lang.Integer, /) -> AccessibilityButtonController: ...
    def getBrailleDisplayController(self) -> BrailleDisplayController: ...
    def getFingerprintGestureController(self) -> FingerprintGestureController: ...
    def getInputMethod(self) -> InputMethod | None: ...
    def getMagnificationController(self) -> AccessibilityService.MagnificationController: ...
    @typing.overload
    def getRootInActiveWindow(self) -> android.view.accessibility.AccessibilityNodeInfo | None: ...
    @typing.overload
    def getRootInActiveWindow(self, prefetchingStrategy: int | java.jint | java.lang.Integer, /) -> android.view.accessibility.AccessibilityNodeInfo | None: ...
    def getServiceInfo(self) -> AccessibilityServiceInfo: ...
    def getSoftKeyboardController(self) -> AccessibilityService.SoftKeyboardController: ...
    def getSystemActions(self) -> java.util.List[android.view.accessibility.AccessibilityNodeInfo.AccessibilityAction]: ...
    def getSystemService(self, name: str | java.lang.String, /) -> java.lang.Object: ...
    def getTouchInteractionController(self, displayId: int | java.jint | java.lang.Integer, /) -> TouchInteractionController: ...
    def getWindows(self) -> java.util.List[android.view.accessibility.AccessibilityWindowInfo]: ...
    def getWindowsOnAllDisplays(self) -> android.util.SparseArray[java.util.List[android.view.accessibility.AccessibilityWindowInfo]]: ...
    def isCacheEnabled(self) -> bool: ...
    def isNodeInCache(self, node: android.view.accessibility.AccessibilityNodeInfo, /) -> bool: ...
    def onAccessibilityEvent(self, arg1: android.view.accessibility.AccessibilityEvent, /) -> None: ...
    def onBind(self, intent: android.content.Intent, /) -> android.os.IBinder: ...
    def onCreateInputMethod(self) -> InputMethod: ...
    @typing.overload
    def onGesture(self, gestureId: int | java.jint | java.lang.Integer, /) -> bool: ...
    @typing.overload
    def onGesture(self, gestureEvent: AccessibilityGestureEvent, /) -> bool: ...
    def onInterrupt(self) -> None: ...
    def onKeyEvent(self, event: android.view.KeyEvent, /) -> bool: ...
    def onMotionEvent(self, event: android.view.MotionEvent, /) -> None: ...
    def onServiceConnected(self) -> None: ...
    def onSystemActionsChanged(self) -> None: ...
    def performGlobalAction(self, action: int | java.jint | java.lang.Integer, /) -> bool: ...
    def setAccessibilityFocusAppearance(self, strokeWidth: int | java.jint | java.lang.Integer, color: int | java.jint | java.lang.Integer, /) -> None: ...
    def setAnimationScale(self, scale: float | java.jfloat | java.lang.Float, /) -> None: ...
    def setCacheEnabled(self, enabled: bool | java.jboolean | java.lang.Boolean, /) -> bool: ...
    def setGestureDetectionPassthroughRegion(self, displayId: int | java.jint | java.lang.Integer, region: android.graphics.Region, /) -> None: ...
    def setServiceInfo(self, info: AccessibilityServiceInfo, /) -> None: ...
    def setTouchExplorationPassthroughRegion(self, displayId: int | java.jint | java.lang.Integer, region: android.graphics.Region, /) -> None: ...
    def takeScreenshot(self, displayId: int | java.jint | java.lang.Integer, executor: java.util.concurrent.Executor, callback: AccessibilityService.TakeScreenshotCallback, /) -> None: ...
    def takeScreenshotOfWindow(self, accessibilityWindowId: int | java.jint | java.lang.Integer, executor: java.util.concurrent.Executor, callback: AccessibilityService.TakeScreenshotCallback, /) -> None: ...

    class TakeScreenshotCallback(java.lang.Object):
        def onFailure(self, arg1: int | java.jint | java.lang.Integer, /) -> None: ...
        def onSuccess(self, arg1: AccessibilityService.ScreenshotResult, /) -> None: ...

    class SoftKeyboardController(java.lang.Object):
        ENABLE_IME_FAIL_BY_ADMIN: typing.ClassVar[int] = ...
        ENABLE_IME_FAIL_UNKNOWN: typing.ClassVar[int] = ...
        ENABLE_IME_SUCCESS: typing.ClassVar[int] = ...
        @typing.overload
        def addOnShowModeChangedListener(self, listener: AccessibilityService.SoftKeyboardController.OnShowModeChangedListener, /) -> None: ...
        @typing.overload
        def addOnShowModeChangedListener(self, listener: AccessibilityService.SoftKeyboardController.OnShowModeChangedListener, handler: android.os.Handler, /) -> None: ...
        def getShowMode(self) -> int: ...
        def removeOnShowModeChangedListener(self, listener: AccessibilityService.SoftKeyboardController.OnShowModeChangedListener, /) -> bool: ...
        def setInputMethodEnabled(self, imeId: str | java.lang.String, enabled: bool | java.jboolean | java.lang.Boolean, /) -> int: ...
        def setShowMode(self, showMode: int | java.jint | java.lang.Integer, /) -> bool: ...
        def switchToInputMethod(self, imeId: str | java.lang.String, /) -> bool: ...

        class OnShowModeChangedListener(java.lang.Object):
            def onShowModeChanged(self, arg1: AccessibilityService.SoftKeyboardController, arg2: int | java.jint | java.lang.Integer, /) -> None: ...

    class ScreenshotResult(java.lang.Object):
        def getColorSpace(self) -> android.graphics.ColorSpace: ...
        def getHardwareBuffer(self) -> android.hardware.HardwareBuffer: ...
        def getTimestamp(self) -> int: ...

    class MagnificationController(java.lang.Object):
        @typing.overload
        def addListener(self, listener: AccessibilityService.MagnificationController.OnMagnificationChangedListener, /) -> None: ...
        @typing.overload
        def addListener(self, listener: AccessibilityService.MagnificationController.OnMagnificationChangedListener, handler: android.os.Handler, /) -> None: ...
        def getCenterX(self) -> float: ...
        def getCenterY(self) -> float: ...
        def getCurrentMagnificationRegion(self) -> android.graphics.Region: ...
        def getMagnificationConfig(self) -> MagnificationConfig: ...
        def getMagnificationRegion(self) -> android.graphics.Region: ...
        def getScale(self) -> float: ...
        def removeListener(self, listener: AccessibilityService.MagnificationController.OnMagnificationChangedListener, /) -> bool: ...
        def reset(self, animate: bool | java.jboolean | java.lang.Boolean, /) -> bool: ...
        def resetCurrentMagnification(self, animate: bool | java.jboolean | java.lang.Boolean, /) -> bool: ...
        def setCenter(self, centerX: float | java.jfloat | java.lang.Float, centerY: float | java.jfloat | java.lang.Float, animate: bool | java.jboolean | java.lang.Boolean, /) -> bool: ...
        def setMagnificationConfig(self, config: MagnificationConfig, animate: bool | java.jboolean | java.lang.Boolean, /) -> bool: ...
        def setScale(self, scale: float | java.jfloat | java.lang.Float, animate: bool | java.jboolean | java.lang.Boolean, /) -> bool: ...

        class OnMagnificationChangedListener(java.lang.Object):
            @typing.overload
            def onMagnificationChanged(self, controller: AccessibilityService.MagnificationController, region: android.graphics.Region, config: MagnificationConfig, /) -> None: ...
            @typing.overload
            def onMagnificationChanged(self, arg1: AccessibilityService.MagnificationController, arg2: android.graphics.Region, arg3: float | java.jfloat | java.lang.Float, arg4: float | java.jfloat | java.lang.Float, arg5: float | java.jfloat | java.lang.Float, /) -> None: ...

    class GestureResultCallback(java.lang.Object):
        def __init__(self) -> None: ...
        def onCancelled(self, gestureDescription: GestureDescription, /) -> None: ...
        def onCompleted(self, gestureDescription: GestureDescription, /) -> None: ...

class AccessibilityServiceInfo(android.os.Parcelable):
    CAPABILITY_CAN_CONTROL_MAGNIFICATION: typing.ClassVar[int] = ...
    CAPABILITY_CAN_PERFORM_GESTURES: typing.ClassVar[int] = ...
    CAPABILITY_CAN_REQUEST_ENHANCED_WEB_ACCESSIBILITY: typing.ClassVar[int] = ...
    CAPABILITY_CAN_REQUEST_FILTER_KEY_EVENTS: typing.ClassVar[int] = ...
    CAPABILITY_CAN_REQUEST_FINGERPRINT_GESTURES: typing.ClassVar[int] = ...
    CAPABILITY_CAN_REQUEST_TOUCH_EXPLORATION: typing.ClassVar[int] = ...
    CAPABILITY_CAN_RETRIEVE_WINDOW_CONTENT: typing.ClassVar[int] = ...
    CAPABILITY_CAN_TAKE_SCREENSHOT: typing.ClassVar[int] = ...
    CREATOR: typing.ClassVar[android.os.Parcelable.Creator[AccessibilityServiceInfo]] = ...
    DEFAULT: typing.ClassVar[int] = ...
    FEEDBACK_ALL_MASK: typing.ClassVar[int] = ...
    FEEDBACK_AUDIBLE: typing.ClassVar[int] = ...
    FEEDBACK_BRAILLE: typing.ClassVar[int] = ...
    FEEDBACK_GENERIC: typing.ClassVar[int] = ...
    FEEDBACK_HAPTIC: typing.ClassVar[int] = ...
    FEEDBACK_SPOKEN: typing.ClassVar[int] = ...
    FEEDBACK_VISUAL: typing.ClassVar[int] = ...
    FLAG_ENABLE_ACCESSIBILITY_VOLUME: typing.ClassVar[int] = ...
    FLAG_INCLUDE_NOT_IMPORTANT_VIEWS: typing.ClassVar[int] = ...
    FLAG_INPUT_METHOD_EDITOR: typing.ClassVar[int] = ...
    FLAG_REPORT_VIEW_IDS: typing.ClassVar[int] = ...
    FLAG_REQUEST_2_FINGER_PASSTHROUGH: typing.ClassVar[int] = ...
    FLAG_REQUEST_ACCESSIBILITY_BUTTON: typing.ClassVar[int] = ...
    FLAG_REQUEST_ENHANCED_WEB_ACCESSIBILITY: typing.ClassVar[int] = ...
    FLAG_REQUEST_FILTER_KEY_EVENTS: typing.ClassVar[int] = ...
    FLAG_REQUEST_FINGERPRINT_GESTURES: typing.ClassVar[int] = ...
    FLAG_REQUEST_MULTI_FINGER_GESTURES: typing.ClassVar[int] = ...
    FLAG_REQUEST_SHORTCUT_WARNING_DIALOG_SPOKEN_FEEDBACK: typing.ClassVar[int] = ...
    FLAG_REQUEST_TOUCH_EXPLORATION_MODE: typing.ClassVar[int] = ...
    FLAG_RETRIEVE_INTERACTIVE_WINDOWS: typing.ClassVar[int] = ...
    FLAG_SEND_MOTION_EVENTS: typing.ClassVar[int] = ...
    FLAG_SERVICE_HANDLES_DOUBLE_TAP: typing.ClassVar[int] = ...
    eventTypes: int = ...
    feedbackType: int = ...
    flags: int = ...
    notificationTimeout: int = ...
    packageNames: java.chaquopy.JavaArray[java.lang.String] = ...
    def __init__(self) -> None: ...
    @staticmethod
    def capabilityToString(capability: int | java.jint | java.lang.Integer, /) -> str: ...
    def describeContents(self) -> int: ...
    def equals(self, obj: java.lang.Object | int | bool | float | str, /) -> bool: ...
    @staticmethod
    def feedbackTypeToString(feedbackType: int | java.jint | java.lang.Integer, /) -> str: ...
    @staticmethod
    def flagToString(flag: int | java.jint | java.lang.Integer, /) -> str: ...
    def getCanRetrieveWindowContent(self) -> bool: ...
    def getCapabilities(self) -> int: ...
    def getDescription(self) -> str: ...
    def getId(self) -> str: ...
    def getInteractiveUiTimeoutMillis(self) -> int: ...
    def getMotionEventSources(self) -> int: ...
    def getNonInteractiveUiTimeoutMillis(self) -> int: ...
    def getResolveInfo(self) -> android.content.pm.ResolveInfo: ...
    def getSettingsActivityName(self) -> str: ...
    def getTileServiceName(self) -> str | None: ...
    def hashCode(self) -> int: ...
    def isAccessibilityTool(self) -> bool: ...
    def loadDescription(self, packageManager: android.content.pm.PackageManager, /) -> str: ...
    def loadIntro(self, packageManager: android.content.pm.PackageManager, /) -> java.lang.CharSequence | None: ...
    def loadSummary(self, packageManager: android.content.pm.PackageManager, /) -> java.lang.CharSequence: ...
    def setInteractiveUiTimeoutMillis(self, timeout: int | java.jint | java.lang.Integer, /) -> None: ...
    def setMotionEventSources(self, motionEventSources: int | java.jint | java.lang.Integer, /) -> None: ...
    def setNonInteractiveUiTimeoutMillis(self, timeout: int | java.jint | java.lang.Integer, /) -> None: ...
    def toString(self) -> str: ...
    def writeToParcel(self, parcel: android.os.Parcel, flagz: int | java.jint | java.lang.Integer, /) -> None: ...

class BrailleDisplayController(java.lang.Object):
    @typing.overload
    def connect(self, arg1: android.bluetooth.BluetoothDevice, arg2: BrailleDisplayController.BrailleDisplayCallback, /) -> None: ...
    @typing.overload
    def connect(self, arg1: android.hardware.usb.UsbDevice, arg2: BrailleDisplayController.BrailleDisplayCallback, /) -> None: ...
    @typing.overload
    def connect(self, arg1: android.bluetooth.BluetoothDevice, arg2: java.util.concurrent.Executor, arg3: BrailleDisplayController.BrailleDisplayCallback, /) -> None: ...
    @typing.overload
    def connect(self, arg1: android.hardware.usb.UsbDevice, arg2: java.util.concurrent.Executor, arg3: BrailleDisplayController.BrailleDisplayCallback, /) -> None: ...
    def disconnect(self) -> None: ...
    def isConnected(self) -> bool: ...
    def write(self, arg1: java.chaquopy.JavaArrayJByte, /) -> None: ...

    class BrailleDisplayCallback(java.lang.Object):
        FLAG_ERROR_BRAILLE_DISPLAY_NOT_FOUND: typing.ClassVar[int] = ...
        FLAG_ERROR_CANNOT_ACCESS: typing.ClassVar[int] = ...
        def onConnected(self, arg1: java.chaquopy.JavaArrayJByte, /) -> None: ...
        def onConnectionFailed(self, arg1: int | java.jint | java.lang.Integer, /) -> None: ...
        def onDisconnected(self) -> None: ...
        def onInput(self, arg1: java.chaquopy.JavaArrayJByte, /) -> None: ...

class FingerprintGestureController(java.lang.Object):
    FINGERPRINT_GESTURE_SWIPE_DOWN: typing.ClassVar[int] = ...
    FINGERPRINT_GESTURE_SWIPE_LEFT: typing.ClassVar[int] = ...
    FINGERPRINT_GESTURE_SWIPE_RIGHT: typing.ClassVar[int] = ...
    FINGERPRINT_GESTURE_SWIPE_UP: typing.ClassVar[int] = ...
    def isGestureDetectionAvailable(self) -> bool: ...
    def registerFingerprintGestureCallback(self, callback: FingerprintGestureController.FingerprintGestureCallback, handler: android.os.Handler, /) -> None: ...
    def unregisterFingerprintGestureCallback(self, callback: FingerprintGestureController.FingerprintGestureCallback, /) -> None: ...

    class FingerprintGestureCallback(java.lang.Object):
        def __init__(self) -> None: ...
        def onGestureDetected(self, gesture: int | java.jint | java.lang.Integer, /) -> None: ...
        def onGestureDetectionAvailabilityChanged(self, available: bool | java.jboolean | java.lang.Boolean, /) -> None: ...

class GestureDescription(java.lang.Object):
    def getDisplayId(self) -> int: ...
    @staticmethod
    def getMaxGestureDuration() -> int: ...
    @staticmethod
    def getMaxStrokeCount() -> int: ...
    def getStroke(self, index: int | java.jint | java.lang.Integer, /) -> GestureDescription.StrokeDescription: ...
    def getStrokeCount(self) -> int: ...

    class StrokeDescription(java.lang.Object):
        @typing.overload
        def __init__(self, path: android.graphics.Path, startTime: int | java.jlong | java.lang.Long, duration: int | java.jlong | java.lang.Long, /) -> None: ...
        @typing.overload
        def __init__(self, path: android.graphics.Path, startTime: int | java.jlong | java.lang.Long, duration: int | java.jlong | java.lang.Long, willContinue: bool | java.jboolean | java.lang.Boolean, /) -> None: ...
        def continueStroke(self, path: android.graphics.Path, startTime: int | java.jlong | java.lang.Long, duration: int | java.jlong | java.lang.Long, willContinue: bool | java.jboolean | java.lang.Boolean, /) -> GestureDescription.StrokeDescription: ...
        def getDuration(self) -> int: ...
        def getPath(self) -> android.graphics.Path: ...
        def getStartTime(self) -> int: ...
        def willContinue(self) -> bool: ...

    class Builder(java.lang.Object):
        def __init__(self) -> None: ...
        def addStroke(self, strokeDescription: GestureDescription.StrokeDescription, /) -> GestureDescription.Builder: ...
        def build(self) -> GestureDescription: ...
        def setDisplayId(self, displayId: int | java.jint | java.lang.Integer, /) -> GestureDescription.Builder: ...

class InputMethod(java.lang.Object):
    def __init__(self, service: AccessibilityService, /) -> None: ...
    def getCurrentInputConnection(self) -> InputMethod.AccessibilityInputConnection | None: ...
    def getCurrentInputEditorInfo(self) -> android.view.inputmethod.EditorInfo | None: ...
    def getCurrentInputStarted(self) -> bool: ...
    def onFinishInput(self) -> None: ...
    def onStartInput(self, attribute: android.view.inputmethod.EditorInfo, restarting: bool | java.jboolean | java.lang.Boolean, /) -> None: ...
    def onUpdateSelection(self, oldSelStart: int | java.jint | java.lang.Integer, oldSelEnd: int | java.jint | java.lang.Integer, newSelStart: int | java.jint | java.lang.Integer, newSelEnd: int | java.jint | java.lang.Integer, candidatesStart: int | java.jint | java.lang.Integer, candidatesEnd: int | java.jint | java.lang.Integer, /) -> None: ...

    class AccessibilityInputConnection(java.lang.Object):
        def clearMetaKeyStates(self, states: int | java.jint | java.lang.Integer, /) -> None: ...
        def commitText(self, text: java.lang.CharSequence, newCursorPosition: int | java.jint | java.lang.Integer, textAttribute: android.view.inputmethod.TextAttribute, /) -> None: ...
        def deleteSurroundingText(self, beforeLength: int | java.jint | java.lang.Integer, afterLength: int | java.jint | java.lang.Integer, /) -> None: ...
        def getCursorCapsMode(self, reqModes: int | java.jint | java.lang.Integer, /) -> int: ...
        def getSurroundingText(self, beforeLength: int | java.jint | java.lang.Integer, afterLength: int | java.jint | java.lang.Integer, flags: int | java.jint | java.lang.Integer, /) -> android.view.inputmethod.SurroundingText: ...
        def performContextMenuAction(self, id: int | java.jint | java.lang.Integer, /) -> None: ...
        def performEditorAction(self, editorAction: int | java.jint | java.lang.Integer, /) -> None: ...
        def sendKeyEvent(self, event: android.view.KeyEvent, /) -> None: ...
        def setSelection(self, start: int | java.jint | java.lang.Integer, end: int | java.jint | java.lang.Integer, /) -> None: ...

class MagnificationConfig(android.os.Parcelable):
    CREATOR: typing.ClassVar[android.os.Parcelable.Creator[MagnificationConfig]] = ...
    MAGNIFICATION_MODE_DEFAULT: typing.ClassVar[int] = ...
    MAGNIFICATION_MODE_FULLSCREEN: typing.ClassVar[int] = ...
    MAGNIFICATION_MODE_WINDOW: typing.ClassVar[int] = ...
    def describeContents(self) -> int: ...
    def getCenterX(self) -> float: ...
    def getCenterY(self) -> float: ...
    def getMode(self) -> int: ...
    def getScale(self) -> float: ...
    def isActivated(self) -> bool: ...
    def toString(self) -> str: ...
    def writeToParcel(self, parcel: android.os.Parcel, flags: int | java.jint | java.lang.Integer, /) -> None: ...

    class Builder(java.lang.Object):
        def __init__(self) -> None: ...
        def build(self) -> MagnificationConfig: ...
        def setActivated(self, activated: bool | java.jboolean | java.lang.Boolean, /) -> MagnificationConfig.Builder: ...
        def setCenterX(self, centerX: float | java.jfloat | java.lang.Float, /) -> MagnificationConfig.Builder: ...
        def setCenterY(self, centerY: float | java.jfloat | java.lang.Float, /) -> MagnificationConfig.Builder: ...
        def setMode(self, mode: int | java.jint | java.lang.Integer, /) -> MagnificationConfig.Builder: ...
        def setScale(self, scale: float | java.jfloat | java.lang.Float, /) -> MagnificationConfig.Builder: ...

class TouchInteractionController(java.lang.Object):
    STATE_CLEAR: typing.ClassVar[int] = ...
    STATE_DELEGATING: typing.ClassVar[int] = ...
    STATE_DRAGGING: typing.ClassVar[int] = ...
    STATE_TOUCH_EXPLORING: typing.ClassVar[int] = ...
    STATE_TOUCH_INTERACTING: typing.ClassVar[int] = ...
    def getDisplayId(self) -> int: ...
    def getMaxPointerCount(self) -> int: ...
    def getState(self) -> int: ...
    def performClick(self) -> None: ...
    def performLongClickAndStartDrag(self) -> None: ...
    def registerCallback(self, executor: java.util.concurrent.Executor, callback: TouchInteractionController.Callback, /) -> None: ...
    def requestDelegating(self) -> None: ...
    def requestDragging(self, pointerId: int | java.jint | java.lang.Integer, /) -> None: ...
    def requestTouchExploration(self) -> None: ...
    @staticmethod
    def stateToString(state: int | java.jint | java.lang.Integer, /) -> str: ...
    def unregisterAllCallbacks(self) -> None: ...
    def unregisterCallback(self, callback: TouchInteractionController.Callback, /) -> bool: ...

    class Callback(java.lang.Object):
        def onMotionEvent(self, arg1: android.view.MotionEvent, /) -> None: ...
        def onStateChanged(self, arg1: int | java.jint | java.lang.Integer, /) -> None: ...
