Android
Android Address Screen
Android example
// launching example
val intent = AddressActivity.Builder.builder
.pickupLatLng(position.latitude, position.longitude)
.addressType(AddressType.PICKUP)
.build(context)
startActivityForResult(intent, AddressCodes.PICKUP)
// result example
override fun onActivityResult(requestCode: Int, resultCode: Int, data: Intent?) {
if (resultCode == RESULT_OK && requestCode == AddressCodes.PICKUP) {
val pickup = data?.getParcelableExtra<LocationInfo>(AddressCodes.DATA_ADDRESS)
}
super.onActivityResult(requestCode, resultCode, data)
}
Builder variables
Variable | Description |
---|---|
addressTyped: AddressType` | The activity will use the addressType to display in its UI whether the user is searching for their pickup or destination.Possible options are AddressType.PICKUP and AddressType.DESTINATION |
locationBias : (latitude : Double , longitude : Double ) | Passes up the latitude and longitude with the address search to help locate the address.The UI SDK’s BookingActivity will supply the latitude and longitude of the current pickup point. |
Builder variables
:
: Passes up the [latitude] and [longitude] with the address search to help locate the address. The UI SDK’s BookingActivity will supply the latitude and longitude of the current pickup point.
Flight Number