import typing

import android.animation
import android.content
import android.graphics
import android.os
import android.util
import android.view
import android.view.animation
import android.widget
import java
import java.chaquopy
import java.lang
import java.util
import java.util.concurrent.atomic
import org.metalev.multitouch.controller
import org.osmdroid
import org.osmdroid.api
import org.osmdroid.events
import org.osmdroid.tileprovider
import org.osmdroid.tileprovider.tilesource
import org.osmdroid.util
import org.osmdroid.views.overlay
import org.osmdroid.views.util.constants

class MapController(org.osmdroid.api.IMapController, org.osmdroid.views.util.constants.MapViewConstants):
    mMapView: MapView = ...
    def __init__(self, mapView: MapView, /) -> None: ...
    @typing.overload
    def animateTo(self, point: org.osmdroid.api.IGeoPoint, /) -> None: ...
    @typing.overload
    def animateTo(self, x: int | java.jint | java.lang.Integer, y: int | java.jint | java.lang.Integer, /) -> None: ...
    def onAnimationEnd(self) -> None: ...
    def onAnimationStart(self) -> None: ...
    def scrollBy(self, x: int | java.jint | java.lang.Integer, y: int | java.jint | java.lang.Integer, /) -> None: ...
    def setCenter(self, point: org.osmdroid.api.IGeoPoint, /) -> None: ...
    def setZoom(self, zoomlevel: int | java.jint | java.lang.Integer, /) -> int: ...
    def stopAnimation(self, jumpToTarget: bool | java.jboolean | java.lang.Boolean, /) -> None: ...
    def stopPanning(self) -> None: ...
    def zoomIn(self) -> bool: ...
    def zoomInFixing(self, xPixel: int | java.jint | java.lang.Integer, yPixel: int | java.jint | java.lang.Integer, /) -> bool: ...
    def zoomOut(self) -> bool: ...
    def zoomOutFixing(self, xPixel: int | java.jint | java.lang.Integer, yPixel: int | java.jint | java.lang.Integer, /) -> bool: ...
    @typing.overload
    def zoomToSpan(self, bb: org.osmdroid.util.BoundingBoxE6, /) -> None: ...
    @typing.overload
    def zoomToSpan(self, latSpanE6: int | java.jint | java.lang.Integer, lonSpanE6: int | java.jint | java.lang.Integer, /) -> None: ...

    class MyZoomAnimationListener(android.view.animation.Animation.AnimationListener):
        def __init__(self, arg1: MapController, /) -> None: ...
        def onAnimationEnd(self, animation: android.view.animation.Animation, /) -> None: ...
        def onAnimationRepeat(self, animation: android.view.animation.Animation, /) -> None: ...
        def onAnimationStart(self, animation: android.view.animation.Animation, /) -> None: ...

    class MyZoomAnimatorUpdateListener(android.animation.ValueAnimator.AnimatorUpdateListener):
        def __init__(self, arg1: MapController, /) -> None: ...
        def onAnimationUpdate(self, animation: android.animation.ValueAnimator, /) -> None: ...

    class MyZoomAnimatorListener(android.animation.AnimatorListenerAdapter):
        def __init__(self, arg1: MapController, /) -> None: ...
        def onAnimationEnd(self, animation: android.animation.Animator, /) -> None: ...
        def onAnimationStart(self, animation: android.animation.Animator, /) -> None: ...

class MapControllerOld(org.osmdroid.api.IMapController, org.osmdroid.views.util.constants.MapViewConstants):
    def __init__(self, osmv: MapView, /) -> None: ...
    @typing.overload
    def animateTo(self, point: org.osmdroid.api.IGeoPoint, /) -> None: ...
    @typing.overload
    def animateTo(self, latitude: float | java.jdouble | java.lang.Double, longitude: float | java.jdouble | java.lang.Double, /) -> None: ...
    @typing.overload
    def animateTo(self, gp: org.osmdroid.util.GeoPoint, aAnimationType: MapControllerOld.AnimationType, /) -> None: ...
    @typing.overload
    def animateTo(self, aLatitudeE6: int | java.jint | java.lang.Integer, aLongitudeE6: int | java.jint | java.lang.Integer, aAnimationType: MapControllerOld.AnimationType, /) -> None: ...
    @typing.overload
    def animateTo(self, gp: org.osmdroid.util.GeoPoint, aAnimationType: MapControllerOld.AnimationType, aSmoothness: int | java.jint | java.lang.Integer, aDuration: int | java.jint | java.lang.Integer, /) -> None: ...
    @typing.overload
    def animateTo(self, aLatitudeE6: int | java.jint | java.lang.Integer, aLongitudeE6: int | java.jint | java.lang.Integer, aAnimationType: MapControllerOld.AnimationType, aSmoothness: int | java.jint | java.lang.Integer, aDuration: int | java.jint | java.lang.Integer, /) -> None: ...
    def scrollBy(self, x: int | java.jint | java.lang.Integer, y: int | java.jint | java.lang.Integer, /) -> None: ...
    def setCenter(self, point: org.osmdroid.api.IGeoPoint, /) -> None: ...
    def setZoom(self, zoomlevel: int | java.jint | java.lang.Integer, /) -> int: ...
    def stopAnimation(self, jumpToTarget: bool | java.jboolean | java.lang.Boolean, /) -> None: ...
    def stopPanning(self) -> None: ...
    def zoomIn(self) -> bool: ...
    @typing.overload
    def zoomInFixing(self, point: org.osmdroid.util.GeoPoint, /) -> bool: ...
    @typing.overload
    def zoomInFixing(self, xPixel: int | java.jint | java.lang.Integer, yPixel: int | java.jint | java.lang.Integer, /) -> bool: ...
    def zoomOut(self) -> bool: ...
    @typing.overload
    def zoomOutFixing(self, point: org.osmdroid.util.GeoPoint, /) -> bool: ...
    @typing.overload
    def zoomOutFixing(self, xPixel: int | java.jint | java.lang.Integer, yPixel: int | java.jint | java.lang.Integer, /) -> bool: ...
    @typing.overload
    def zoomToSpan(self, bb: org.osmdroid.util.BoundingBoxE6, /) -> None: ...
    @typing.overload
    def zoomToSpan(self, reqLatSpan: int | java.jint | java.lang.Integer, reqLonSpan: int | java.jint | java.lang.Integer, /) -> None: ...

    class MiddlePeakSpeedAnimationRunner(MapControllerOld.CosinusalBasedAnimationRunner, org.osmdroid.views.util.constants.MathConstants):
        @typing.overload
        def __init__(self, arg1: MapControllerOld, aTargetLatitudeE6: int | java.jint | java.lang.Integer, aTargetLongitudeE6: int | java.jint | java.lang.Integer, /) -> None: ...
        @typing.overload
        def __init__(self, arg1: MapControllerOld, aTargetLatitudeE6: int | java.jint | java.lang.Integer, aTargetLongitudeE6: int | java.jint | java.lang.Integer, aSmoothness: int | java.jint | java.lang.Integer, aDuration: int | java.jint | java.lang.Integer, /) -> None: ...

    class HalfCosinusalDeceleratingAnimationRunner(MapControllerOld.CosinusalBasedAnimationRunner, org.osmdroid.views.util.constants.MathConstants):
        @typing.overload
        def __init__(self, arg1: MapControllerOld, aTargetLatitudeE6: int | java.jint | java.lang.Integer, aTargetLongitudeE6: int | java.jint | java.lang.Integer, /) -> None: ...
        @typing.overload
        def __init__(self, arg1: MapControllerOld, aTargetLatitudeE6: int | java.jint | java.lang.Integer, aTargetLongitudeE6: int | java.jint | java.lang.Integer, aSmoothness: int | java.jint | java.lang.Integer, aDuration: int | java.jint | java.lang.Integer, /) -> None: ...

    class QuarterCosinusalDeceleratingAnimationRunner(MapControllerOld.CosinusalBasedAnimationRunner, org.osmdroid.views.util.constants.MathConstants):
        @typing.overload
        def __init__(self, arg1: MapControllerOld, aTargetLatitudeE6: int | java.jint | java.lang.Integer, aTargetLongitudeE6: int | java.jint | java.lang.Integer, /) -> None: ...
        @typing.overload
        def __init__(self, arg1: MapControllerOld, aTargetLatitudeE6: int | java.jint | java.lang.Integer, aTargetLongitudeE6: int | java.jint | java.lang.Integer, aSmoothness: int | java.jint | java.lang.Integer, aDuration: int | java.jint | java.lang.Integer, /) -> None: ...

    class AnimationType(java.lang.Enum[MapControllerOld.AnimationType]):
        EXPONENTIALDECELERATING: typing.ClassVar[MapControllerOld.AnimationType] = ...
        HALFCOSINUSALDECELERATING: typing.ClassVar[MapControllerOld.AnimationType] = ...
        LINEAR: typing.ClassVar[MapControllerOld.AnimationType] = ...
        MIDDLEPEAKSPEED: typing.ClassVar[MapControllerOld.AnimationType] = ...
        QUARTERCOSINUSALDECELERATING: typing.ClassVar[MapControllerOld.AnimationType] = ...
        @staticmethod
        def valueOf(name: str | java.lang.String, /) -> MapControllerOld.AnimationType: ...
        @staticmethod
        def values() -> java.chaquopy.JavaArray[MapControllerOld.AnimationType]: ...

class MapView(android.view.ViewGroup, org.metalev.multitouch.controller.MultiTouchController.MultiTouchObjectCanvas[java.lang.Object], org.osmdroid.api.IMapView, org.osmdroid.views.util.constants.MapViewConstants):
    mIsAnimating: java.util.concurrent.atomic.AtomicBoolean = ...
    mIsFlinging: bool = ...
    mListener: org.osmdroid.events.MapListener = ...
    mMaximumZoomLevel: int = ...
    mMinimumZoomLevel: int = ...
    mMultiTouchScale: float = ...
    mMultiTouchScalePoint: android.graphics.PointF = ...
    mScrollableAreaBoundingBox: org.osmdroid.util.BoundingBoxE6 = ...
    mScrollableAreaLimit: android.graphics.Rect = ...
    mTargetZoomLevel: java.util.concurrent.atomic.AtomicInteger = ...
    @typing.overload
    def __init__(self, context: android.content.Context, tileSizePixels: int | java.jint | java.lang.Integer, /) -> None: ...
    @typing.overload
    def __init__(self, context: android.content.Context, attrs: android.util.AttributeSet, /) -> None: ...
    @typing.overload
    def __init__(self, context: android.content.Context, tileSizePixels: int | java.jint | java.lang.Integer, resourceProxy: org.osmdroid.ResourceProxy, /) -> None: ...
    @typing.overload
    def __init__(self, context: android.content.Context, tileSizePixels: int | java.jint | java.lang.Integer, resourceProxy: org.osmdroid.ResourceProxy, aTileProvider: org.osmdroid.tileprovider.MapTileProviderBase, /) -> None: ...
    @typing.overload
    def __init__(self, context: android.content.Context, tileSizePixels: int | java.jint | java.lang.Integer, resourceProxy: org.osmdroid.ResourceProxy, aTileProvider: org.osmdroid.tileprovider.MapTileProviderBase, tileRequestCompleteHandler: android.os.Handler, /) -> None: ...
    @typing.overload
    def __init__(self, context: android.content.Context, tileSizePixels: int | java.jint | java.lang.Integer, resourceProxy: org.osmdroid.ResourceProxy, tileProvider: org.osmdroid.tileprovider.MapTileProviderBase, tileRequestCompleteHandler: android.os.Handler, attrs: android.util.AttributeSet, /) -> None: ...
    def canZoomIn(self) -> bool: ...
    def canZoomOut(self) -> bool: ...
    def checkLayoutParams(self, p: android.view.ViewGroup.LayoutParams, /) -> bool: ...
    def computeScroll(self) -> None: ...
    def dispatchDraw(self, c: android.graphics.Canvas, /) -> None: ...
    def dispatchTouchEvent(self, event: android.view.MotionEvent, /) -> bool: ...
    def generateDefaultLayoutParams(self) -> android.view.ViewGroup.LayoutParams: ...
    @typing.overload
    def generateLayoutParams(self, attrs: android.util.AttributeSet, /) -> android.view.ViewGroup.LayoutParams: ...
    @typing.overload
    def generateLayoutParams(self, p: android.view.ViewGroup.LayoutParams, /) -> android.view.ViewGroup.LayoutParams: ...
    def getBoundingBox(self) -> org.osmdroid.util.BoundingBoxE6: ...
    def getController(self) -> org.osmdroid.api.IMapController: ...
    def getDraggableObjectAtPoint(self, pt: org.metalev.multitouch.controller.MultiTouchController.PointInfo, /) -> java.lang.Object: ...
    def getIntrinsicScreenRect(self, reuse: android.graphics.Rect, /) -> android.graphics.Rect: ...
    def getLatitudeSpan(self) -> int: ...
    def getLongitudeSpan(self) -> int: ...
    def getMapCenter(self) -> org.osmdroid.api.IGeoPoint: ...
    def getMapOrientation(self) -> float: ...
    def getMaxZoomLevel(self) -> int: ...
    def getMinZoomLevel(self) -> int: ...
    def getOverlayManager(self) -> org.osmdroid.views.overlay.OverlayManager: ...
    def getOverlays(self) -> java.util.List[org.osmdroid.views.overlay.Overlay]: ...
    def getPositionAndScale(self, obj: java.lang.Object | int | bool | float | str, objPosAndScaleOut: org.metalev.multitouch.controller.MultiTouchController.PositionAndScale, /) -> None: ...
    def getProjection(self) -> Projection: ...
    def getResourceProxy(self) -> org.osmdroid.ResourceProxy: ...
    def getScreenRect(self, reuse: android.graphics.Rect, /) -> android.graphics.Rect: ...
    def getScrollableAreaLimit(self) -> org.osmdroid.util.BoundingBoxE6: ...
    def getScroller(self) -> android.widget.Scroller: ...
    def getTileProvider(self) -> org.osmdroid.tileprovider.MapTileProviderBase: ...
    def getTileRequestCompleteHandler(self) -> android.os.Handler: ...
    @typing.overload
    def getZoomLevel(self) -> int: ...
    @typing.overload
    def getZoomLevel(self, aPending: bool | java.jboolean | java.lang.Boolean, /) -> int: ...
    @typing.overload
    def invalidateMapCoordinates(self, dirty: android.graphics.Rect, /) -> None: ...
    @typing.overload
    def invalidateMapCoordinates(self, left: int | java.jint | java.lang.Integer, top: int | java.jint | java.lang.Integer, right: int | java.jint | java.lang.Integer, bottom: int | java.jint | java.lang.Integer, /) -> None: ...
    def isAnimating(self) -> bool: ...
    def onDetach(self) -> None: ...
    def onDetachedFromWindow(self) -> None: ...
    def onKeyDown(self, keyCode: int | java.jint | java.lang.Integer, event: android.view.KeyEvent, /) -> bool: ...
    def onKeyUp(self, keyCode: int | java.jint | java.lang.Integer, event: android.view.KeyEvent, /) -> bool: ...
    def onLayout(self, changed: bool | java.jboolean | java.lang.Boolean, l: int | java.jint | java.lang.Integer, t: int | java.jint | java.lang.Integer, r: int | java.jint | java.lang.Integer, b: int | java.jint | java.lang.Integer, /) -> None: ...
    def onMeasure(self, widthMeasureSpec: int | java.jint | java.lang.Integer, heightMeasureSpec: int | java.jint | java.lang.Integer, /) -> None: ...
    def onTouchEvent(self, event: android.view.MotionEvent, /) -> bool: ...
    def onTrackballEvent(self, event: android.view.MotionEvent, /) -> bool: ...
    def postInvalidateMapCoordinates(self, left: int | java.jint | java.lang.Integer, top: int | java.jint | java.lang.Integer, right: int | java.jint | java.lang.Integer, bottom: int | java.jint | java.lang.Integer, /) -> None: ...
    def scrollTo(self, x: int | java.jint | java.lang.Integer, y: int | java.jint | java.lang.Integer, /) -> None: ...
    def selectObject(self, obj: java.lang.Object | int | bool | float | str, pt: org.metalev.multitouch.controller.MultiTouchController.PointInfo, /) -> None: ...
    def setBackgroundColor(self, pColor: int | java.jint | java.lang.Integer, /) -> None: ...
    def setBuiltInZoomControls(self, on: bool | java.jboolean | java.lang.Boolean, /) -> None: ...
    def setMapListener(self, ml: org.osmdroid.events.MapListener, /) -> None: ...
    def setMapOrientation(self, degrees: float | java.jfloat | java.lang.Float, /) -> None: ...
    def setMaxZoomLevel(self, zoomLevel: int | java.jint | java.lang.Integer, /) -> None: ...
    def setMinZoomLevel(self, zoomLevel: int | java.jint | java.lang.Integer, /) -> None: ...
    def setMultiTouchControls(self, on: bool | java.jboolean | java.lang.Boolean, /) -> None: ...
    def setPositionAndScale(self, obj: java.lang.Object | int | bool | float | str, aNewObjPosAndScale: org.metalev.multitouch.controller.MultiTouchController.PositionAndScale, aTouchPoint: org.metalev.multitouch.controller.MultiTouchController.PointInfo, /) -> bool: ...
    def setScrollableAreaLimit(self, boundingBox: org.osmdroid.util.BoundingBoxE6, /) -> None: ...
    def setTileSource(self, aTileSource: org.osmdroid.tileprovider.tilesource.ITileSource, /) -> None: ...
    def setUseDataConnection(self, aMode: bool | java.jboolean | java.lang.Boolean, /) -> None: ...
    def useDataConnection(self) -> bool: ...
    def zoomToBoundingBox(self, boundingBox: org.osmdroid.util.BoundingBoxE6, /) -> None: ...

    class LayoutParams(android.view.ViewGroup.LayoutParams):
        BOTTOM_CENTER: typing.ClassVar[int] = ...
        BOTTOM_LEFT: typing.ClassVar[int] = ...
        BOTTOM_RIGHT: typing.ClassVar[int] = ...
        CENTER: typing.ClassVar[int] = ...
        CENTER_LEFT: typing.ClassVar[int] = ...
        CENTER_RIGHT: typing.ClassVar[int] = ...
        TOP_CENTER: typing.ClassVar[int] = ...
        TOP_LEFT: typing.ClassVar[int] = ...
        TOP_RIGHT: typing.ClassVar[int] = ...
        alignment: int = ...
        geoPoint: org.osmdroid.api.IGeoPoint = ...
        offsetX: int = ...
        offsetY: int = ...
        @typing.overload
        def __init__(self, source: android.view.ViewGroup.LayoutParams, /) -> None: ...
        @typing.overload
        def __init__(self, c: android.content.Context, attrs: android.util.AttributeSet, /) -> None: ...
        @typing.overload
        def __init__(self, width: int | java.jint | java.lang.Integer, height: int | java.jint | java.lang.Integer, geoPoint: org.osmdroid.api.IGeoPoint, alignment: int | java.jint | java.lang.Integer, offsetX: int | java.jint | java.lang.Integer, offsetY: int | java.jint | java.lang.Integer, /) -> None: ...

class Projection(org.osmdroid.api.IProjection, org.osmdroid.views.util.constants.MapViewConstants):
    mMultiTouchScale: float = ...
    mOffsetX: int = ...
    mOffsetY: int = ...
    def adjustForDateLine(self, x: int | java.jint | java.lang.Integer, y: int | java.jint | java.lang.Integer, reuse: android.graphics.Point, /) -> android.graphics.Point: ...
    @typing.overload
    def fromPixels(self, x: int | java.jint | java.lang.Integer, y: int | java.jint | java.lang.Integer, /) -> org.osmdroid.api.IGeoPoint: ...
    @typing.overload
    def fromPixels(self, x: int | java.jint | java.lang.Integer, y: int | java.jint | java.lang.Integer, reuse: org.osmdroid.util.GeoPoint, /) -> org.osmdroid.api.IGeoPoint: ...
    def getBoundingBox(self) -> org.osmdroid.util.BoundingBoxE6: ...
    def getIntrinsicScreenRect(self) -> android.graphics.Rect: ...
    def getInvertedScaleRotateCanvasMatrix(self) -> android.graphics.Matrix: ...
    def getMapOrientation(self) -> float: ...
    def getNorthEast(self) -> org.osmdroid.api.IGeoPoint: ...
    def getScreenRect(self) -> android.graphics.Rect: ...
    def getSouthWest(self) -> org.osmdroid.api.IGeoPoint: ...
    def getZoomLevel(self) -> int: ...
    def metersToEquatorPixels(self, meters: float | java.jfloat | java.lang.Float, /) -> float: ...
    def metersToPixels(self, meters: float | java.jfloat | java.lang.Float, /) -> float: ...
    def rotateAndScalePoint(self, x: int | java.jint | java.lang.Integer, y: int | java.jint | java.lang.Integer, reuse: android.graphics.Point, /) -> android.graphics.Point: ...
    def toMercatorPixels(self, x: int | java.jint | java.lang.Integer, y: int | java.jint | java.lang.Integer, reuse: android.graphics.Point, /) -> android.graphics.Point: ...
    def toPixels(self, in_: org.osmdroid.api.IGeoPoint, reuse: android.graphics.Point, /) -> android.graphics.Point: ...
    def toPixelsFromMercator(self, x: int | java.jint | java.lang.Integer, y: int | java.jint | java.lang.Integer, reuse: android.graphics.Point, /) -> android.graphics.Point: ...
    def toPixelsFromProjected(self, in_: android.graphics.Point, reuse: android.graphics.Point, /) -> android.graphics.Point: ...
    @typing.overload
    def toProjectedPixels(self, geoPoint: org.osmdroid.util.GeoPoint, reuse: android.graphics.Point, /) -> android.graphics.Point: ...
    @typing.overload
    def toProjectedPixels(self, latituteE6: int | java.jint | java.lang.Integer, longitudeE6: int | java.jint | java.lang.Integer, reuse: android.graphics.Point, /) -> android.graphics.Point: ...
    def unrotateAndScalePoint(self, x: int | java.jint | java.lang.Integer, y: int | java.jint | java.lang.Integer, reuse: android.graphics.Point, /) -> android.graphics.Point: ...
