Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • OpenLayers 2.10 Beginner's Guide
  • Toc
  • feedback
OpenLayers 2.10 Beginner's Guide

OpenLayers 2.10 Beginner's Guide

4.2 (9)
close
OpenLayers 2.10 Beginner's Guide

OpenLayers 2.10 Beginner's Guide

4.2 (9)

Overview of this book

Table of Contents (18 chapters)
close
OpenLayers 2.10
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Strategy class


The strategy class is used to determine how the vector layer will request data and what it does with the feature data. Strategies can be used together—for example, the BBOX and Cluster strategies can be both used at the same time. Each subclass is quite different from each other, so let's take a look at each of the subclasses.

Strategy.BBOX

This class is used to display data that is within the map's extent. When used with the WFS protocol, it will set up the request to grab only the data that falls within the map's extent. If you are working with a lot of feature data, using the BBOX strategy will be quite helpful, as you'll only get back the data that is within the visible extent. This is possible only with some sort of feature server though—a static file won't know what to do with the requests passed in map extent, and will always return back every feature which the static file contains.

Strategy.Cluster

This will cluster features together based on a distance and optional threshold...

Unlock full access

Continue reading for free

A Packt free trial gives you instant online access to our library of over 7000 practical eBooks and videos, constantly updated with the latest in tech
bookmark search playlist font-size

Change the font size

margin-width

Change margin width

day-mode

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Delete Bookmark

Modal Close icon
Are you sure you want to delete it?
Cancel
Yes, Delete