Added in API level 33

GeocodeListener

interface GeocodeListener
android.location.Geocoder.GeocodeListener

A listener for asynchronous geocoding results.

Summary

Public methods
open Unit
onError(errorMessage: String?)

Invoked when geocoding fails, with a brief error message.

abstract Unit

Invoked when geocoding completes successfully.

Public methods

onError

Added in API level 33
open fun onError(errorMessage: String?): Unit

Invoked when geocoding fails, with a brief error message.

Parameters
errorMessage String?: This value may be null.

onGeocode

Added in API level 33
abstract fun onGeocode(addresses: MutableList<Address!>): Unit

Invoked when geocoding completes successfully. May return an empty list.

Parameters
addresses MutableList<Address!>: This value cannot be null.