kony.map Namespace Constants
The kony.map namespace defines the following constants.
The Map Provider Constants enable your app to select which map provider to use.
Constant | Description |
---|---|
kony.map.MAP_PROVIDER_BING | Select Bing as the map provider. |
kony.map.MAP_PROVIDER_GOOGLE | Select Google as the map provider. |
Use the Map View Mode Constants to configure which map view your app selects.
Constant | Description |
---|---|
kony.map.MAP_VIEW_MODE_NORMAL | View the map in whatever mode is the default for the map provider. |
kony.map.MAP_VIEW_MODE_SATELLITE | View the map as a satellite image. |
kony.map.MAP_VIEW_MODE_STREET | View the map as a street map. |
kony.map.MAP_VIEW_MODE_TRAFFIC | View traffic information on the map. |
The following table lists the error codes that the Map widget generates.
Constant | Description |
---|---|
kony.map.ROUTE_SEARCH_INVALID_REQUEST | The format of the route search request was invalid. |
kony.map.ROUTE_SEARCH_LIMIT_EXCEEDED |
The service has received too many requests from your application within the allowed time period. For Android, below are the usage limits imposed by Google Map Service.
|
kony.map.ROUTE_SEARCH_NETWORK_FAILURE | The request failed due to network failure. |
kony.map.ROUTE_SEARCH_PLACE_NOT_FOUND | At least one of the locations specified in the request's source, destination, or waypoints could not be found. |
kony.map.ROUTE_SEARCH_UNKNOWN_ERROR | An unknown error occurred. |
The Pin Image Anchor Constants define the positions that your app can anchor a pin image to on a map. The image positions are illustrated in the image below.
Constant | Description |
---|---|
kony.map.PIN_IMG_ANCHOR_BOTTOM_CENTER | Anchors the pin image at the bottom center position. |
kony.map.PIN_IMG_ANCHOR_BOTTOM_LEFT | Anchors the pin image by its lower left corner. |
kony.map.PIN_IMG_ANCHOR_BOTTOM_RIGHT | Anchors the pin image by its lower right corner. |
kony.map.PIN_IMG_ANCHOR_CENTER | Anchors the pin image at the center position. |
kony.map.PIN_IMG_ANCHOR_MIDDLE_LEFT | Anchors the pin image at the middle left position of the image. |
kony.map.PIN_IMG_ANCHOR_MIDDLE_RIGHT | Anchors the pin image at the middle right position of the image. |
kony.map.PIN_IMG_ANCHOR_TOP_CENTER | Anchors the pin image at the top center position. |
kony.map.PIN_IMG_ANCHOR_TOP_LEFT | Anchors the pin image by its upper left corner. |
kony.map.PIN_IMG_ANCHOR_TOP_RIGHT | Anchors the pin image by its upper right corner. |
These constants define the types of images that can be used with maps.
Constant | Description |
---|---|
kony.map.PIN_IMG_SRC_TYPE_BASE64 | Indicates that the pin image should be created out of given a base64 string. |
kony.map.PIN_IMG_SRC_TYPE_FILE_PATH | Indicates that the pin image is available in internal file system. The specified value can be either an absolute path or a File object. |
kony.map.PIN_IMG_SRC_TYPE_IMAGE | Indicates that the pin image is of type Image object |
kony.map.PIN_IMG_SRC_TYPE_RESOURCES |
Indicates that the pin image is available in bundled resources. |
The following constants identify the shapes that can be drawn on maps.
Constant | Description |
---|---|
kony.map.SHAPE_TYPE_POLYGON | The shape is a polygon. |
kony.map.SHAPE_TYPE_POLYLINE | The shape is a polyline. |
kony.map.SHAPE_TYPE_CIRCLE | The shape is a circle. |