Re: Drop lastPosition from Geolocation?

On Nov 19, 2008, at 9:15 AM, Greg Bolsinga wrote:

> On Nov 18, 2008, at 9:38 AM, Doug Turner wrote:
>> Instead, I think we can do something different and both have a  
>> asynchronous API and get the last position the browser saw by  
>> adding a new PositionOption:
>> interface PositionOptions {
>>   ...
>>   attribute unsigned long modifiedSince;
>> };
>> The modifiedSince value specified in (seconds provides a hint that  
>> the application would like a cached position as so long as it has  
>> been updated within the time specified.  If the UA does not have a  
>> cached position, the modifiedSince option will be ignored.
> Is this time 'age', as in the Position is at least "modifiedSince"  
> seconds old?

I was thinking it would be something like -- the web app could say, "I  
don't care if the location is a bit stale".  So, if a web app passed  
600 as the modifiedSince, that would mean that the UA could return a  
position that is <= 10 minutes old.

> An alternative could be if the UA can't provide a position within  
> the PositionOptions timeout parameter, it will return the last  
> position obtained by the UA, across all pages? This would need a  
> flag supplied to let the developer know they are getting potentially  
> stale data. Perhaps this can be a Position field in the  
> PositionError that is lastPosition, only set when the error code is  

That is an idea.  I am not sure I like returning a position at all in  
most error cases.

Received on Wednesday, 19 November 2008 17:20:18 UTC