How a map tool works – Pitney Bowes MapXtreme User Manual
Page 85

Chapter 5: Web Applications, Controls, and Tools
Web Control Architecture
MapXtreme v7.1
85
Developer Guide
The client Command generates a URL request that is sent to the server, which then processes the
response to display the new map.
The interaction object can be null. This means there is no client side interaction, such as pan, zoom,
point select, that will fire off the command automatically. The command can still be fired, but it would
have to be done programmatically.
Server Side Command Architecture
On the server, the MapInfo.WebControls.MapControlModel class handles the URL request sent
from the client. This class contains methods for carrying out basic map navigation commands such
as pan and zoom, as well as selection commands for selecting points, polygons, and features within
drawn rectangles and radii. The InvokeCommand method locates the specified tool command and
calls its Execute method. Execute calls the RestoreState, then Process, and then finally SaveState.
To perform commands other than those provided in this class, you must write a Command class that
extends the WebControls.MapBaseCommand class.
How a Map Tool Works
The following describes a typical request/response cycle for a web map tool, in this case, a Zoom-In
tool. You can create custom map tools using this same architecture. See
The numbers in the diagram refer to the stages described below.
1. A user draws a rectangle around the general area of Europe displayed in a MapControl using a
Zoom-In tool.