org.opengts.war.tools
Interface MapProvider

All Known Implementing Classes:
ESRIMaps, GoogleMaps, JSMap, MapProviderAdapter, Mapstraction, OpenLayers, VirtualEarth

public interface MapProvider


Field Summary
static double DEFAULT_LATITUDE
           
static double DEFAULT_LONGITUDE
           
static long FEATURE_CENTER_ON_LAST
           
static long FEATURE_CORRIDORS
           
static long FEATURE_DETAIL_INFO_BOX
           
static long FEATURE_DETAIL_REPORT
           
static long FEATURE_DISTANCE_RULER
           
static long FEATURE_GEOZONES
           
static long FEATURE_LATLON_DISPLAY
           
static long FEATURE_REPLAY_POINTS
           
static java.lang.String ID_DETAIL_CONTROL
           
static java.lang.String ID_DETAIL_TABLE
           
static java.lang.String ID_DISTANCE_DISPLAY
           
static java.lang.String ID_LAT_LON_DISPLAY
           
static java.lang.String ID_LATEST_BATTERY
           
static java.lang.String ID_LATEST_EVENT_DATE
           
static java.lang.String ID_LATEST_EVENT_TIME
           
static java.lang.String ID_LATEST_EVENT_TMZ
           
static java.lang.String ID_MESSAGE_TEXT
           
static java.lang.String ID_ZONE_LATITUDE_
           
static java.lang.String ID_ZONE_LONGITUDE_
           
static java.lang.String ID_ZONE_RADIUS_M
           
static int MAP_HEIGHT
           
static int MAP_WIDTH
           
static java.lang.String[] PROP_auto_count_device
           
static java.lang.String[] PROP_auto_count_fleet
           
static java.lang.String[] PROP_auto_enable_device
           
static java.lang.String[] PROP_auto_enable_fleet
           
static java.lang.String[] PROP_auto_interval_device
           
static java.lang.String[] PROP_auto_interval_fleet
           
static java.lang.String[] PROP_auto_onload_device
           
static java.lang.String[] PROP_auto_onload_fleet
           
static java.lang.String[] PROP_combineSpeedHeading
           
static java.lang.String[] PROP_default_latitude
           
static java.lang.String[] PROP_default_longitude
           
static java.lang.String[] PROP_default_zoom
           
static java.lang.String[] PROP_detail_showSatCount
           
static java.lang.String[] PROP_iconSel_fleet
           
static java.lang.String[] PROP_iconSel_fleet_legend
           
static java.lang.String[] PROP_iconSelector
           
static java.lang.String[] PROP_iconSelector_legend
           
static java.lang.String[] PROP_info_inclBlankAddress
           
static java.lang.String[] PROP_info_inclBlankOptFields
           
static java.lang.String[] PROP_info_showAltitude
           
static java.lang.String[] PROP_info_showOptionalFields
           
static java.lang.String[] PROP_info_showSpeed
           
static java.lang.String[] PROP_javascript_inline
           
static java.lang.String[] PROP_javascript_src
           
static java.lang.String[] PROP_map_fillFrame
           
static java.lang.String[] PROP_map_height
           
static java.lang.String[] PROP_map_includeGeozones
           
static java.lang.String[] PROP_map_maxCreationAge
           
static java.lang.String[] PROP_map_minProximity
           
static java.lang.String[] PROP_map_pushpins
           
static java.lang.String[] PROP_map_routeLine
           
static java.lang.String[] PROP_map_routeLine_arrows
           
static java.lang.String[] PROP_map_routeLine_color
           
static java.lang.String[] PROP_map_routeLine_snapToRoad
           
static java.lang.String[] PROP_map_view
           
static java.lang.String[] PROP_map_width
           
static java.lang.String[] PROP_maxPushpins_device
           
static java.lang.String[] PROP_maxPushpins_fleet
           
static java.lang.String[] PROP_maxPushpins_report
           
static java.lang.String[] PROP_pushpin_zoom
           
static java.lang.String[] PROP_replay_enable
           
static java.lang.String[] PROP_replay_interval
           
static java.lang.String[] PROP_replay_singlePushpin
           
static java.lang.String[] PROP_scrollWheelZoom
           
static java.lang.String[] PROP_zone_map_corridor
           
static java.lang.String[] PROP_zone_map_height
           
static java.lang.String[] PROP_zone_map_multipoint
           
static java.lang.String[] PROP_zone_map_polygon
           
static java.lang.String[] PROP_zone_map_width
           
static int ZONE_HEIGHT
           
static int ZONE_WIDTH
           
 
Method Summary
 java.lang.String getAuthorization()
          Returns the MapProvider authorization String/Key (passed to the map service provider)
 long getAutoUpdateCount(boolean isFleet)
          Returns the auto-update count
 boolean getAutoUpdateEnabled(boolean isFleet)
          Returns true if auto-update is enabled
 long getAutoUpdateInterval(boolean isFleet)
          Returns the auto-update interval in seconds
 boolean getAutoUpdateOnLoad(boolean isFleet)
          Returns true if auto-update on-load is enabled
 java.lang.String[] getCorridorInstructions(java.util.Locale loc)
          Returns the localized GeoCorridor instructions
 GeoPoint getDefaultCenter(GeoPoint dft)
          Returns the default map center (when no pushpins are displayed)
 double getDefaultZoom(double dft, boolean withPushpins)
          Returns the default zoom level
 MapDimension getDimension()
          Returns the MapDimension for this MapProvider
 java.lang.String[] getGeozoneInstructions(int type, java.util.Locale loc)
          Returns the localized Geozone instructions
 int getGeozoneSupportedPointCount(int type)
          Gets the number of supported Geozone points
 int getHeight()
          Returns the Height from the MapDimension
 java.lang.String getIconSelector(RequestProperties reqState)
          Gets the icon selector for the current map
 java.lang.String getIconSelectorLegend(RequestProperties reqState)
          Gets the IconSelector legend displayed on the map page to indicate the type of pushpins displayed on the map.
 long getMaxPushpins(RequestProperties reqState)
          Gets the maximum number of allowed pushpins on the map at one time
 java.lang.String getName()
          Returns the MapProvider name
 RTProperties getProperties()
          Returns the properties for this MapProvider
 OrderedMap<java.lang.String,PushpinIcon> getPushpinIconMap(RequestProperties reqState)
          Gets the pushpin icon map
 boolean getReplayEnabled()
          Returns true if replay is enabled
 long getReplayInterval()
          Returns the replay interval in seconds
 boolean getReplaySinglePushpin()
          Returns true if only a single pushpin is to be displayed at a time during replay
 int getWidth()
          Returns the Width from the MapDimension
 MapDimension getZoneDimension()
          Returns the Geozone MapDimension for this MapProvider
 int getZoneHeight()
          Returns the Geozone Height from the MapDimension
 int getZoneWidth()
          Returns the Geozone Width from the MapDimension
 boolean isFeatureSupported(long featureMask)
          Returns true if the specified feature is supported
 void setProperties(java.lang.String props)
          Sets the properties for this MapProvider.
 void writeJavaScript(java.io.PrintWriter out, RequestProperties reqState)
          Writes any required JavaScript to the specified PrintWriter.
 void writeMapCell(java.io.PrintWriter out, RequestProperties reqState, MapDimension mapDim)
          Writes map cell to the specified PrintWriter.
 void writeMapUpdate(int mapDataFormat, RequestProperties reqState)
          Updates the points to the current displayed map
 void writeMapUpdate(java.io.PrintWriter out, int indentLvl, int mapDataFormat, boolean isTopLevelTag, RequestProperties reqState)
          Updates the points to the current displayed map
 void writeStyle(java.io.PrintWriter out, RequestProperties reqState)
          Writes any required CSS to the specified PrintWriter.
 

Field Detail

FEATURE_GEOZONES

static final long FEATURE_GEOZONES
See Also:
Constant Field Values

FEATURE_LATLON_DISPLAY

static final long FEATURE_LATLON_DISPLAY
See Also:
Constant Field Values

FEATURE_DISTANCE_RULER

static final long FEATURE_DISTANCE_RULER
See Also:
Constant Field Values

FEATURE_DETAIL_REPORT

static final long FEATURE_DETAIL_REPORT
See Also:
Constant Field Values

FEATURE_DETAIL_INFO_BOX

static final long FEATURE_DETAIL_INFO_BOX
See Also:
Constant Field Values

FEATURE_REPLAY_POINTS

static final long FEATURE_REPLAY_POINTS
See Also:
Constant Field Values

FEATURE_CENTER_ON_LAST

static final long FEATURE_CENTER_ON_LAST
See Also:
Constant Field Values

FEATURE_CORRIDORS

static final long FEATURE_CORRIDORS
See Also:
Constant Field Values

ID_DETAIL_TABLE

static final java.lang.String ID_DETAIL_TABLE
See Also:
Constant Field Values

ID_DETAIL_CONTROL

static final java.lang.String ID_DETAIL_CONTROL
See Also:
Constant Field Values

ID_LAT_LON_DISPLAY

static final java.lang.String ID_LAT_LON_DISPLAY
See Also:
Constant Field Values

ID_DISTANCE_DISPLAY

static final java.lang.String ID_DISTANCE_DISPLAY
See Also:
Constant Field Values

ID_LATEST_EVENT_DATE

static final java.lang.String ID_LATEST_EVENT_DATE
See Also:
Constant Field Values

ID_LATEST_EVENT_TIME

static final java.lang.String ID_LATEST_EVENT_TIME
See Also:
Constant Field Values

ID_LATEST_EVENT_TMZ

static final java.lang.String ID_LATEST_EVENT_TMZ
See Also:
Constant Field Values

ID_LATEST_BATTERY

static final java.lang.String ID_LATEST_BATTERY
See Also:
Constant Field Values

ID_MESSAGE_TEXT

static final java.lang.String ID_MESSAGE_TEXT
See Also:
Constant Field Values

ID_ZONE_RADIUS_M

static final java.lang.String ID_ZONE_RADIUS_M
See Also:
Constant Field Values

ID_ZONE_LATITUDE_

static final java.lang.String ID_ZONE_LATITUDE_
See Also:
Constant Field Values

ID_ZONE_LONGITUDE_

static final java.lang.String ID_ZONE_LONGITUDE_
See Also:
Constant Field Values

MAP_WIDTH

static final int MAP_WIDTH
See Also:
Constant Field Values

MAP_HEIGHT

static final int MAP_HEIGHT
See Also:
Constant Field Values

ZONE_WIDTH

static final int ZONE_WIDTH
See Also:
Constant Field Values

ZONE_HEIGHT

static final int ZONE_HEIGHT
See Also:
Constant Field Values

PROP_zone_map_width

static final java.lang.String[] PROP_zone_map_width

PROP_zone_map_height

static final java.lang.String[] PROP_zone_map_height

PROP_zone_map_multipoint

static final java.lang.String[] PROP_zone_map_multipoint

PROP_zone_map_polygon

static final java.lang.String[] PROP_zone_map_polygon

PROP_zone_map_corridor

static final java.lang.String[] PROP_zone_map_corridor

PROP_map_width

static final java.lang.String[] PROP_map_width

PROP_map_height

static final java.lang.String[] PROP_map_height

PROP_map_fillFrame

static final java.lang.String[] PROP_map_fillFrame

PROP_maxPushpins_device

static final java.lang.String[] PROP_maxPushpins_device

PROP_maxPushpins_fleet

static final java.lang.String[] PROP_maxPushpins_fleet

PROP_maxPushpins_report

static final java.lang.String[] PROP_maxPushpins_report

PROP_map_pushpins

static final java.lang.String[] PROP_map_pushpins

PROP_map_maxCreationAge

static final java.lang.String[] PROP_map_maxCreationAge

PROP_map_routeLine

static final java.lang.String[] PROP_map_routeLine

PROP_map_routeLine_color

static final java.lang.String[] PROP_map_routeLine_color

PROP_map_routeLine_arrows

static final java.lang.String[] PROP_map_routeLine_arrows

PROP_map_routeLine_snapToRoad

static final java.lang.String[] PROP_map_routeLine_snapToRoad

PROP_map_view

static final java.lang.String[] PROP_map_view

PROP_map_minProximity

static final java.lang.String[] PROP_map_minProximity

PROP_map_includeGeozones

static final java.lang.String[] PROP_map_includeGeozones

PROP_pushpin_zoom

static final java.lang.String[] PROP_pushpin_zoom

PROP_default_zoom

static final java.lang.String[] PROP_default_zoom

PROP_default_latitude

static final java.lang.String[] PROP_default_latitude

PROP_default_longitude

static final java.lang.String[] PROP_default_longitude

PROP_info_showSpeed

static final java.lang.String[] PROP_info_showSpeed

PROP_info_showAltitude

static final java.lang.String[] PROP_info_showAltitude

PROP_info_inclBlankAddress

static final java.lang.String[] PROP_info_inclBlankAddress

PROP_info_showOptionalFields

static final java.lang.String[] PROP_info_showOptionalFields

PROP_info_inclBlankOptFields

static final java.lang.String[] PROP_info_inclBlankOptFields

PROP_detail_showSatCount

static final java.lang.String[] PROP_detail_showSatCount

PROP_auto_enable_device

static final java.lang.String[] PROP_auto_enable_device

PROP_auto_onload_device

static final java.lang.String[] PROP_auto_onload_device

PROP_auto_interval_device

static final java.lang.String[] PROP_auto_interval_device

PROP_auto_count_device

static final java.lang.String[] PROP_auto_count_device

PROP_auto_enable_fleet

static final java.lang.String[] PROP_auto_enable_fleet

PROP_auto_onload_fleet

static final java.lang.String[] PROP_auto_onload_fleet

PROP_auto_interval_fleet

static final java.lang.String[] PROP_auto_interval_fleet

PROP_auto_count_fleet

static final java.lang.String[] PROP_auto_count_fleet

PROP_replay_enable

static final java.lang.String[] PROP_replay_enable

PROP_replay_interval

static final java.lang.String[] PROP_replay_interval

PROP_replay_singlePushpin

static final java.lang.String[] PROP_replay_singlePushpin

PROP_combineSpeedHeading

static final java.lang.String[] PROP_combineSpeedHeading

PROP_iconSelector

static final java.lang.String[] PROP_iconSelector

PROP_iconSelector_legend

static final java.lang.String[] PROP_iconSelector_legend

PROP_iconSel_fleet

static final java.lang.String[] PROP_iconSel_fleet

PROP_iconSel_fleet_legend

static final java.lang.String[] PROP_iconSel_fleet_legend

PROP_javascript_src

static final java.lang.String[] PROP_javascript_src

PROP_javascript_inline

static final java.lang.String[] PROP_javascript_inline

PROP_scrollWheelZoom

static final java.lang.String[] PROP_scrollWheelZoom

DEFAULT_LATITUDE

static final double DEFAULT_LATITUDE
See Also:
Constant Field Values

DEFAULT_LONGITUDE

static final double DEFAULT_LONGITUDE
See Also:
Constant Field Values
Method Detail

getName

java.lang.String getName()
Returns the MapProvider name

Returns:
The MapProvider name

getAuthorization

java.lang.String getAuthorization()
Returns the MapProvider authorization String/Key (passed to the map service provider)

Returns:
The MapProvider authorization String/Key.

setProperties

void setProperties(java.lang.String props)
Sets the properties for this MapProvider.

Parameters:
props - A String representation of the properties to set in this MapProvider. The String must be in the form "key=value key=value ...".

getProperties

RTProperties getProperties()
Returns the properties for this MapProvider

Returns:
The properties for this MapProvider

getMaxPushpins

long getMaxPushpins(RequestProperties reqState)
Gets the maximum number of allowed pushpins on the map at one time

Parameters:
reqState - The session RequestProperties instance
Returns:
The maximum number of allowed pushpins on the map

getPushpinIconMap

OrderedMap<java.lang.String,PushpinIcon> getPushpinIconMap(RequestProperties reqState)
Gets the pushpin icon map

Parameters:
reqState - The RequestProperties for the current session
Returns:
The PushPinIcon map

getIconSelector

java.lang.String getIconSelector(RequestProperties reqState)
Gets the icon selector for the current map

Parameters:
reqState - The RequestProperties for the current session
Returns:
The icon selector String

getIconSelectorLegend

java.lang.String getIconSelectorLegend(RequestProperties reqState)
Gets the IconSelector legend displayed on the map page to indicate the type of pushpins displayed on the map.

Parameters:
reqState - The RequestProperties for the current session
Returns:
The IconSelector legend (in html format)

getDimension

MapDimension getDimension()
Returns the MapDimension for this MapProvider

Returns:
The MapDimension

getWidth

int getWidth()
Returns the Width from the MapDimension

Returns:
The MapDimension width

getHeight

int getHeight()
Returns the Height from the MapDimension

Returns:
The MapDimension height

getZoneDimension

MapDimension getZoneDimension()
Returns the Geozone MapDimension for this MapProvider

Returns:
The Geozone MapDimension

getZoneWidth

int getZoneWidth()
Returns the Geozone Width from the MapDimension

Returns:
The Geozone MapDimension width

getZoneHeight

int getZoneHeight()
Returns the Geozone Height from the MapDimension

Returns:
The Geozone MapDimension height

getDefaultCenter

GeoPoint getDefaultCenter(GeoPoint dft)
Returns the default map center (when no pushpins are displayed)

Parameters:
dft - The GeoPoint center to return if not otherwised overridden
Returns:
The default map center

getDefaultZoom

double getDefaultZoom(double dft,
                      boolean withPushpins)
Returns the default zoom level

Parameters:
dft - The default zoom level to return
withPushpins - If true, return the default zoom level is at least one pushpin is displayed.
Returns:
The default zoom level

getAutoUpdateEnabled

boolean getAutoUpdateEnabled(boolean isFleet)
Returns true if auto-update is enabled

Parameters:
isFleet - True for fleet map
Returns:
True if auto-updated is enabled

getAutoUpdateOnLoad

boolean getAutoUpdateOnLoad(boolean isFleet)
Returns true if auto-update on-load is enabled

Parameters:
isFleet - True for fleet map
Returns:
True if auto-updated on-load is enabled

getAutoUpdateInterval

long getAutoUpdateInterval(boolean isFleet)
Returns the auto-update interval in seconds

Parameters:
isFleet - True for fleet map
Returns:
The auto-update interval in seconds

getAutoUpdateCount

long getAutoUpdateCount(boolean isFleet)
Returns the auto-update count

Parameters:
isFleet - True for fleet map
Returns:
The auto-update count (-1 for indefinate)

getReplayEnabled

boolean getReplayEnabled()
Returns true if replay is enabled

Returns:
True if replay is enabled

getReplayInterval

long getReplayInterval()
Returns the replay interval in seconds

Returns:
The replay interval in seconds

getReplaySinglePushpin

boolean getReplaySinglePushpin()
Returns true if only a single pushpin is to be displayed at a time during replay

Returns:
True if only a single pushpin is to be displayed at a time during replay

writeStyle

void writeStyle(java.io.PrintWriter out,
                RequestProperties reqState)
                throws java.io.IOException
Writes any required CSS to the specified PrintWriter. This method is intended to be overridden to provide the required behavior.

Parameters:
out - The PrintWriter
reqState - The session RequestProperties
Throws:
java.io.IOException

writeJavaScript

void writeJavaScript(java.io.PrintWriter out,
                     RequestProperties reqState)
                     throws java.io.IOException
Writes any required JavaScript to the specified PrintWriter. This method is intended to be overridden to provide the required behavior.

Parameters:
out - The PrintWriter
reqState - The session RequestProperties
Throws:
java.io.IOException

writeMapCell

void writeMapCell(java.io.PrintWriter out,
                  RequestProperties reqState,
                  MapDimension mapDim)
                  throws java.io.IOException
Writes map cell to the specified PrintWriter. This method is intended to be overridden to provide the required behavior for the specific MapProvider

Parameters:
out - The PrintWriter
reqState - The session RequestProperties
mapDim - The MapDimension
Throws:
java.io.IOException

writeMapUpdate

void writeMapUpdate(int mapDataFormat,
                    RequestProperties reqState)
                    throws java.io.IOException
Updates the points to the current displayed map

Parameters:
reqState - The session RequestProperties
Throws:
java.io.IOException

writeMapUpdate

void writeMapUpdate(java.io.PrintWriter out,
                    int indentLvl,
                    int mapDataFormat,
                    boolean isTopLevelTag,
                    RequestProperties reqState)
                    throws java.io.IOException
Updates the points to the current displayed map

Parameters:
out - The output PrintWriter
indentLvl - The indentation level (0 for no indentation)
reqState - The session RequestProperties
Throws:
java.io.IOException

getGeozoneSupportedPointCount

int getGeozoneSupportedPointCount(int type)
Gets the number of supported Geozone points

Parameters:
type - The Geozone type
Returns:
The number of supported points.

getGeozoneInstructions

java.lang.String[] getGeozoneInstructions(int type,
                                          java.util.Locale loc)
Returns the localized Geozone instructions

Parameters:
type - The Geozone type
loc - The current Locale
Returns:
An array of instruction line items

getCorridorInstructions

java.lang.String[] getCorridorInstructions(java.util.Locale loc)
Returns the localized GeoCorridor instructions

Parameters:
loc - The current Locale
Returns:
An array of instruction line items

isFeatureSupported

boolean isFeatureSupported(long featureMask)
Returns true if the specified feature is supported

Parameters:
featureMask - The feature mask to test
Returns:
True if the specified feature is supported