GoogleMaps JSP Tag Library
Tag event
Adds an event listener to the parent tag. This tag can only effectively be a child of a <googlemaps:map> or <googlemaps:marker> tag. If a child of any other tag, this tag will register itself with the next highest instance of <googlemaps:map> or <googlemaps:marker>. When a map or marker with a registered event is triggered, the URL is called additional parameters based upon the parent component type and the event that is triggered. The complete list is as follows:
- <googlemaps:box>
- click
Triggers when the box is clicked on. - component
The box's id. - map
The parent map's id. - event
The event type that was triggered. - type
Returns 'box'.
- dblclick
Triggers when the box is double-clicked on. - component
The box's id. - map
The parent map's id. - event
The event type that was triggered. - type
Returns 'box'.
- <googlemaps:circle>
- click
Triggers when the circle is clicked on. - component
The circle's id. - map
The parent map's id. - event
The event type that was triggered. - type
Returns 'circle'.
- dblclick
Triggers when the circle is double-clicked on. - component
The circle's id. - map
The parent map's id. - event
The event type that was triggered. - type
Returns 'circle'.
- <googlemaps:marker>
- click
Triggers when the marker is clicked on. - component
The marker's id. - map
The parent map's id. - event
The event type that was triggered. - type
Returns 'marker'.
- dblclick
Triggers when the marker is double-clicked on. - component
The marker's id. - map
The parent map's id. - event
The event type that was triggered. - type
Returns 'marker'.
- dragstart
Triggers when a draggable marker is initially dragged. - component
The marker's id. - map
The parent map's id. - event
The event type that was triggered. - type
Returns 'marker'. - longitude
The longitude where the drag was initiated. - latitude
The latitude where the drag was initiated.
- dragend
Triggers when a draggable marker is dropped. - component
The marker's id. - map
The parent map's id. - event
The event type that was triggered. - type
Returns 'marker'. - longitude
The longitude where the marker was dropped. - latitude
The latitude where the marker was dropped.
- <googlemaps:polyline>
- click
Triggers when the polyline is clicked on. - component
The polyline's id. - map
The parent map's id. - event
The event type that was triggered. - type
Returns 'polyline'.
- dblclick
Triggers when the polyline is double-clicked on. - component
The polyline's id. - map
The parent map's id. - event
The event type that was triggered. - type
Returns 'polyline'.
- <googlemaps:polygon>
- click
Triggers when the polygon is clicked on. - component
The polygon's id. - map
The parent map's id. - event
The event type that was triggered. - type
Returns 'polygon'.
- dblclick
Triggers when the polygon is double-clicked on. - component
The polygon's id. - map
The parent map's id. - event
The event type that was triggered. - type
Returns 'polygon'.
- <googlemaps:map>
- click
Triggers when the map is clicked on. - longitude
The longitude where the click occurred. - latitude
The latitude where the click occurred. - map
The parent map's id. - event
The event type that was triggered.
- dblclick
Triggers when the map is double-clicked on. - longitude
The longitude where the click occurred. - latitude
The latitude where the click occurred. - map
The parent map's id. - event
The event type that was triggered.
- moveend
Triggers when the user has completed moving the map. - longitude
The longitude of the new centerpoint for the map. - latitude
The latitude of the new centerpoint for the map. - map
The parent map's id. - event
The event type that was triggered.
- zoom
Triggers when the user changes the zoom level. - zoom
The new zoom level of the map. - map
The parent map's id. - event
The event type that was triggered.
- maptypechanged
- type
Returns the new map type (map, satellite or hybrid). - map
The parent map's id. - event
The event type that was triggered.
The intended use is to have the event trigger a request to either a servlet or JSP page. This page would retrieve the map from the session using the map id (passed as map parameter) making the required changes, additions, etc. and then pass the response back to the requesting page or another page that displays that map, which would then render the map with the changes.
For this methodology to work properly, the parent map must have a scope of type site, so the receiving entity can locate the map from the session.
| Tag Information |
| Tag Class | com.lamatek.tags.google.GoogleMapEventTag |
| TagExtraInfo Class | None |
| Body Content | empty |
| Display Name | GoogleMapEventTag |
| Attributes |
| Name | Required | Request-time | Type | Description |
| action | true | true | java.lang.String | The javascript event that triggers this URL. |
| url | true | true | java.lang.String | The URL that is called when the event is triggered. The URL is appended with parameters based on the component and event type triggered. |
| asynchronous | false | true | boolean | Denotes this action as asynchronous, if true, or synchronous, if false. If false, the request will forward to the specified URL. If true, the request will be made asynchronously. Typically speaking if your URL only needs to know about the data, you can set this to true. If your request needs to render special changes to the map, or redirect to another page, set this to false. |
| Variables |
No Variables Defined. |
Output Generated by
Tag Library Documentation Generator.
Java, JSP, and JavaServer Pages are trademarks or
registered trademarks of Sun Microsystems, Inc. in the US and other
countries. Copyright 2002-4 Sun Microsystems, Inc.
4150 Network Circle
Santa Clara, CA 95054, U.S.A.
All Rights Reserved.