BrazeGeofenceManager

class BrazeGeofenceManager(context: Context, apiKey: String, val brazeManager: IBrazeManager, configurationProvider: BrazeConfigurationProvider, serverConfigStorageProvider: ServerConfigStorageProvider, internalIEventMessenger: IEventMessenger) : IGeofenceManager, IBrazeGeofenceLocationUpdateListener

Constructors

Link copied to clipboard
constructor(context: Context, apiKey: String, brazeManager: IBrazeManager, configurationProvider: BrazeConfigurationProvider, serverConfigStorageProvider: ServerConfigStorageProvider, internalIEventMessenger: IEventMessenger)

Types

Link copied to clipboard
object Companion

Properties

Functions

Link copied to clipboard
Link copied to clipboard
open override fun configureFromServerConfig(serverConfig: ServerConfig)
Link copied to clipboard

Performs the setup required to initialize Geofences on the device, including registering Geofences on the device. when location permissions are granted to the app by the user.

Link copied to clipboard

Together with GeofenceUtils.getGeofencesEnabledFromServerConfig determines whether the geofence feature is enabled for the current app run. Both checks must be satisfied for geofences to be enabled.

Link copied to clipboard
open override fun onLocationRequestComplete(location: IBrazeLocation?)

Informs the BrazeGeofenceManager about the result of the last single location request.

Link copied to clipboard
open override fun postGeofenceReport(geofenceId: String, transitionType: GeofenceTransitionType)
Link copied to clipboard
open override fun registerGeofences(geofenceList: List<BrazeGeofence>)
Link copied to clipboard
Link copied to clipboard
open override fun requestGeofenceRefresh(location: IBrazeLocation)
open override fun requestGeofenceRefresh(ignoreRateLimit: Boolean)

Requests a single location update from Google Play Services.

Link copied to clipboard
fun setUpGeofences(reRegisterGeofences: Boolean)

If reRegisterGeofences is true, re-registers geofences with Google Play Services.

Link copied to clipboard

Unregister all Braze geofences from Google Play Services and delete all locally stored geofences. This method should only be used when geofences are newly disabled via server config.

Link copied to clipboard
open override fun unregisterGeofences()