Class LastKnownLocationInfoManager

java.lang.Object
org.prebid.mobile.rendering.sdk.BaseManager
org.prebid.mobile.rendering.sdk.deviceData.managers.LastKnownLocationInfoManager
All Implemented Interfaces:
LocationInfoManager

public final class LastKnownLocationInfoManager extends BaseManager implements LocationInfoManager
  • Constructor Details

    • LastKnownLocationInfoManager

      public LastKnownLocationInfoManager(android.content.Context context)
  • Method Details

    • resetLocation

      public void resetLocation()
      Specified by:
      resetLocation in interface LocationInfoManager
    • isBetterLocation

      protected boolean isBetterLocation(android.location.Location location, android.location.Location currentBestLocation)
      Determine whether one Location reading is better than the current Location fix
      Parameters:
      location - The new Location that you want to evaluate
      currentBestLocation - The current Location fix, to which you want to compare the new one
    • getLatitude

      public Double getLatitude()
      Description copied from interface: LocationInfoManager
      Get the latitude.
      Specified by:
      getLatitude in interface LocationInfoManager
      Returns:
      the latitude
      See Also:
      • LocationListener
    • getLongitude

      public Double getLongitude()
      Description copied from interface: LocationInfoManager
      Get the longitude.
      Specified by:
      getLongitude in interface LocationInfoManager
      Returns:
      the longitude
      See Also:
      • LocationListener
    • getAccuracy

      public Float getAccuracy()
      Specified by:
      getAccuracy in interface LocationInfoManager
    • getElapsedSeconds

      public Long getElapsedSeconds()
      Specified by:
      getElapsedSeconds in interface LocationInfoManager
    • isLocationAvailable

      public boolean isLocationAvailable()
      Specified by:
      isLocationAvailable in interface LocationInfoManager