Nokia Maps API Reference

Contents

Class nokia.Settings

Class Summary

An observable static class that keeps API settings. Class is used as a storage for data that is used API-wide such as defaultLanguage, appId, authenticationToken. Properties of the class are suppoused to be set via set method and shouldn't be set directly.
Example:
nokia.Settings.set("defaultLanguage", "en-GB")
nokia.Settings.set("appId", "YOUR APPID")
nokia.Settings.set("authenticationToken", "YOUR TOKEN")

Method Summary
static addObserver (name, callback, [context]) This method registers an observer for the property named by the caller.
static set (name, value) This method sets property values, using the property names and values supplied by the caller.
Field Summary
static String appId An id which authenticates the requested application or Web page.
static String authenticationToken A token which authenticates the requested application or Web page.
static String defaultLanguage The default language used by all service managers.
static removeObserver This method unregisters a previously registered observer from the property named by the caller.
Method Detail
static addObserver (name, callback, [context])
This method registers an observer for the property named by the caller.
Parameters:
{String} name The name of the property to observe
{Function} callback The function to be called if the observed property is modified; the function must be able to receive the following arguments:
  • (Variant) value - the new value that the property should be set to
{Object} [context]: The context in which the given function should be called (default null)
static set (name, value)
This method sets property values, using the property names and values supplied by the caller.
Parameters:
{String} name The name of the property to be set
{Variant} value The value that should be applied to the property
Field Detail
static String appId
An id which authenticates the requested application or Web page. The third-party offering comes with an inbuilt id, limited to a certain amount of requests per day. Property is not supposed to be set directly set method should be used instead.
static String authenticationToken
A token which authenticates the requested application or Web page. The third-party offering comes with an in-built token, limited to a certain amount of requests per day. Property is not supposed to be set directly set method should be used instead.
static String defaultLanguage
The default language used by all service managers. Must be given as a string combining an ISO639-1 language code and the relevant ISO3166-1 alpha-2 country code, for example, "en-US". Property is not suppoused to be set directly set method should be used instead.
static removeObserver
This method unregisters a previously registered observer from the property named by the caller.
Documentation generated on Wed Jun 27 2012 16:54:08 GMT+0200 (CEST).