Nokia Maps API Reference

Contents

Class nokia.maps.routing.Manager

Class Summary

The Manager acts as a proxy to the routing service and is responsible for storing the currently selected routes.

Method Summary
addObserver (key, callback, [context]) : nokia.maps.util.OObject This method registers an observer for the property named by the caller.
clear () This method clears all the stored routes.
destroy () This method cleans up the given instance of routing.Manager before releasing it from memory.
get (key) : Variant This method retrieves the value of the property with the name provided by the caller.
getErrorCause () : nokia.maps.routing.ServiceError This method returns the cause of an error.
getRoutes (waypoints, modes) : nokia.maps.routing.Route[] This method retrieves routes that have been calculated by the back end.
remove (key) : nokia.maps.util.OObject This method removes the property with the name provided by the caller.
removeObserver (key, callback, context) : nokia.maps.util.OObject This method removes the observer for the property named by the caller.
set (nameOrObject, [value, [force]]) : nokia.maps.util.OObject This method sets property values, using the property names and values supplied by the caller.
Field Summary
nokia.maps.routing.Route routes This property holds an array of objects that represent calculated routes.
String state This property holds the state of the request sent by the given instance of the Manager.
Direct Inheritance
Constructor Detail

Acts as a proxy to the routing service and is responsible for storing the currently selected routes.

new nokia.maps.routing.Manager()
Method Detail
clear ()
This method clears all the stored routes.
destroy ()
This method cleans up the given instance of routing.Manager before releasing it from memory. The method is especially useful when you use asynchronous code, because it kills coroutines thus preventing errors.
getErrorCause () : nokia.maps.routing.ServiceError
This method returns the cause of an error.
Returns:
{nokia.maps.routing.ServiceError} The error object containing the error type
getRoutes (waypoints, modes) : nokia.maps.routing.Route[]
This method retrieves routes that have been calculated by the back end.
Parameters:
{nokia.maps.routing.WaypointParameterList} waypoints A list of waypoints containing start, destination, and and optional via points; the list represents the basis for a route calculation
{nokia.maps.routing.Mode[]} modes An array of objects that define the modes for the routes to be calculated
Returns:
{nokia.maps.routing.Route[]} The routes returned by the backend. // To be implemented by deriving classes. /** This method invokes the back-end calculateRoute service.
Field Detail
This property holds an array of objects that represent calculated routes.
String state
This property holds the state of the request sent by the given instance of the Manager. The possible values are: "initial", "started", "finished", "failed" and "cleared".
Documentation generated on Tue May 08 2012 10:23:48 GMT+0200 (CEST).