Class nokia.Features
Class Summary
This class provides facilities that allow you to register and load individual functional components
(features) of the API. It automatically resolves dependencies between features and provides mechanisms
to detect the best feature implementation for the current environment.
A feature may exist in different implementations for different target environments.
A feature implementation is a set of classes that provide certain functionality and can
be loaded to enrich the functionality set accessible through the API. The features that can be loaded
individually with the help of the methods on this class include such components as "routing" and "search".
By default, the API loads all possible features in the optimal implementation for the environment
in which it runs. However, the loading of certain features may also be deferred by explicitly
disallowing certain or all features at page-load time. This may reduce the initial page load
time by limiting the amount of API code that is transferred and executed before the page contents are
fully displayed.
Features is a static object that cannot be instantiated, therefore to call one of its methods,
you must precede the method name with the namespace and the name of the class, using the dot
notation. For example, you can call the load() method as follows (we assume that the argument
refers to a real map object as described in the documentation for load()):
nokia.Features.load(myMapOfFeautesToLoad);
Method Summary
static
add
(featureName, featureImplName, loadPath, [detector, [dependencies, [overrides, [charset]]]])
This method adds a new feature implementation definition to the feature registry.
static
get
(featureName, [featureImplName])
This method retrieves a feature implementation definition object for the feature specified by the caller.
static
getFeatureMap
()
This method retrieves a map object containing the names of available implementations for each registered feature.
static
getLoadedMap
()
This method retrieves a map of the names of fully loaded implementations for each registered feature.
static
isLoaded
(featureName, featureImplName)
: Boolean
This method checks whether a certain feature implementation has been successfully loaded.
static
load
(requested, [onSuccess, [onError, [doc, [sync]]]])
This method loads a set of features specified by the caller.
Method Detail
static
add
(featureName, featureImplName, loadPath, [detector, [dependencies, [overrides, [charset]]]])
static
get
(featureName, [featureImplName])
static
isLoaded
(featureName, featureImplName)
: Boolean
static
load
(requested, [onSuccess, [onError, [doc, [sync]]]])
Documentation generated on Wed Jun 27 2012 16:54:29 GMT+0200 (CEST).