An encapsulation of various parameters for requesting the current location through
Nested Class Summary
|class||CurrentLocationRequest.Builder||A builder for
Inherited Constant Summary
Public Method Summary
The duration in milliseconds of the location request used to derive the current location if no historical location satisfies the current location request.
The maximum age of any location returned for this request.
Inherited Method Summary
writeToParcel(Parcel arg0, int arg1)
public boolean equals (Object object)
public long getDurationMillis ()
The duration in milliseconds of the location request used to derive the current location if no historical location satisfies the current location request. If this duration expires with no location, the current location request will return a null location. The current location request may fail and return a null location after a shorter duration (ie, the given duration may be capped internally), but never a longer duration.
public int getGranularity ()
of locations returned for this request. This controls whether fine or coarse locations
may be returned.
public long getMaxUpdateAgeMillis ()
The maximum age of any location returned for this request. A value of 0 indicates
that only freshly derived locations will be returned, and no historical locations will
ever be returned. A value
represents an effectively unbounded maximum age.
NOTE: This parameter applies only to historical locations. Freshly derived locations should almost always have timestamps close to the present time - however it is possible under unlikely conditions for location derivation to take longer than expected, in which case freshly derived locations may have slightly older timestamps.