[OpenLayers-Users] explain openlayers.strategy
Mohammed Rashad
mohammedrashadkm at gmail.com
Tue Dec 13 10:33:23 EST 2011
thanks All, the confusion gone . please mark this discussion as closed :)
thanks OpenLayers users...
On Tue, Dec 13, 2011 at 8:47 PM, Fernando <fnorte at gmail.com> wrote:
> Take it easy Mohammed,
>
> The strategy is usually combined with Protocol and/or Format Classes, it's
> about 'time' and data. The Strategy class it's used to determine what to do
> with a data returned from a protocol, before became visible in an layer.
>
> See an example, that I found in a good book about OpenLayers, that I
> recomend to buy or stfw (OpenLayers 2.10 - Begginer's Guide, by Erik
> Hazzard, from PACKT Publishing):
>
> *var vector_layer = new OpenLayers.Layer.Vector('More Advanced
> Vector Layer',{*
> * protocol: new OpenLayers.Protocol.HTTP({*
> * url: 'some_data.json',*
> * format: new OpenLayers.Format.GeoJSON({})*
> * }),*
> * strategies: [new OpenLayers.Strategy.Fixed()]*
> *});*
> *
> *
> *The above code would use the HTTP Protocol class and use the GeoJSON
> format. Notice how the format is actually part of the protocol object. The
> Fixed Strategy class is also used, which essentially just causes the vector
> layer to request features once and never request new features again.*
>
> Did you get it, now?
>
> Cya,
>
> Fernando G. Norte
> BHte - MG
> cel: +55 31 9119 8814
> -------------------------
> MSN e Gtalk # fnorte at gmail.com
>
>
> 2011/12/13 Mohammed Rashad <mohammedrashadkm at gmail.com>
>
>> i already read the openlayers documentation.Atleast you should think
>> that people may have looked google search pages before asking to a list
>> thanks for your help
>>
>> but I need more . OpenLayers people who developed it may have more idea
>> on it
>>
>> I am waiting for them to answer....
>>
>>
>> On Tue, Dec 13, 2011 at 7:34 PM, Ian Turton <ijturton at gmail.com> wrote:
>>
>>>
>>>
>>> On 13 December 2011 13:20, Mohammed Rashad <mohammedrashadkm at gmail.com>wrote:
>>>
>>>> Hi All,
>>>> Any one please tell me what is strategy?
>>>> How it works?
>>>> How to use it?
>>>>
>>>
>>> *http://www.google.co.uk/search?q=openlayers+strategy*
>>>
>>> --
>>> Ian Turton
>>>
>>>
>>
>>
>> --
>> Regards,
>>
>>
>>
>> _______________________________________________
>> Users mailing list
>> Users at lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/openlayers-users
>>
>>
>
--
Regards,
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20111213/10bd8e92/attachment.html
More information about the Users
mailing list