com.hedgehog.gdzietabiedra.appservice / LocationWatchdog
LocationWatchdog
class LocationWatchdog
(source)
Constructors
Name | Summary |
---|---|
<init> | LocationWatchdog(context: Context ) |
Properties
Name | Summary |
---|---|
context | val context: Context |
Functions
Name | Summary |
---|---|
getLocation | fun getLocation(): Observable < Position > BehaviorSubject that returns current Position of user - default is WARSAW when no other is known |
locationEnabledSubject | fun locationEnabledSubject(): BehaviorSubject < Boolean > BehaviorSubject that returns Boolean - true if location is enabled by user and false if it’s not |
register | fun register(): Unit Register to location data change, it should be called ASAP |
unregister | fun unregister(): Unit Unregister from location data changes, should be called when app is pausing |