Interface CustomerLocationService
- All Known Implementing Classes:
DefaultCustomerLocationService
public interface CustomerLocationService
Defines an API to handle a user's location
-
Method Summary
Modifier and TypeMethodDescriptiondoublecalculateDistance(GeoPoint origin, PointOfServiceModel pointOfServiceModel) Calculates distance between given origin point and given point of service data objectReturns user stored location or null if no location found for current session user.voidsetUserLocation(UserLocationData userLocationData) Stores the information of user location.
-
Method Details
-
setUserLocation
Stores the information of user location. If search term is given, but gps is null it tries to determine GPS coordinates for the given search term.- Parameters:
userLocationData- user location data to be stored.
-
getUserLocation
UserLocationData getUserLocation()Returns user stored location or null if no location found for current session user.- Returns:
- stored location
-
calculateDistance
Calculates distance between given origin point and given point of service data object- Parameters:
origin- origin pointpointOfServiceModel- point of service details- Returns:
- distance between given points
-