new mmir.Core.setToCompatibilityMode3Extension(mmir)
Set to "backwards compatibility mode v3" (for pre version 4.0) for module names and method names.
This function adds old names/synonyms for modules names (on
mmir
object/namespace):
-
mmir.CommonUtils
as mmir.util -
mmir.ConfigurationManager
as mmir.conf -
mmir.ControllerManager
as mmir.ctrl -
mmir.Constants
as mmir.const -
mmir.DialogManager
as mmir.dialog -
mmir.InputManager
as mmir.input -
mmir.LanguageManager
as mmir.lang -
mmir.MediaManager
as mmir.media -
mmir.ModelManager
as mmir.model -
mmir.NotificationManager
as mmir.notifier -
mmir.PresentationManager
as mmir.presentation -
mmir.SemanticInterpreter
as mmir.semantic
-
mmir.ConfigurationManager
- getInstance (removed) for
mmir.ConfigurationManager
- getInstance (removed) for
-
mmir.Constants
- getInstance (removed) for
mmir.Constants
- getInstance (removed) for
-
mmir.ControllerManager
- get for
mmir.ControllerManager#getController
- getNames for
mmir.ControllerManager#getControllerNames
- getInstance (removed) for
mmir.ControllerManager
- get for
-
mmir.DialogManager
- getInstance (removed) for
mmir.DialogManager
- getInstance (removed) for
-
mmir.InputManager
- getInstance (removed) for
mmir.InputManager
- getInstance (removed) for
-
mmir.LanguageManager
- getInstance (removed) for
mmir.LanguageManager
- getInstance (removed) for
-
mmir.ModelManager
- get for
mmir.ModelManager#getController
- getNames for
mmir.ModelManager#getControllerNames
- getInstance (removed) for
mmir.ModelManager
- get for
-
mmir.ModelManager
- get for
mmir.ModelManager#getController
- getNames for
mmir.ModelManager#getControllerNames
- getInstance (removed) for
mmir.ModelManager
- get for
-
mmir.NotificationManager
- getInstance (removed) for
mmir.NotificationManager
- getInstance (removed) for
-
mmir.PresentationManager
- renderView for
mmir.PresentationManager#render
- getInstance (removed) for
mmir.PresentationManager
- renderView for
-
mmir.parser.ParserUtils
- getInstance (removed) for
mmir.parser.ParserUtils
- getInstance (removed) for
-
mmir.parser.RenderUtils
- getInstance (removed) for
mmir.parser.RenderUtils
- getInstance (removed) for
-
mmir.SemanticInterpreter
- getASRSemantic for
mmir.SemanticInterpreter#interpret
- getInstance (removed) for
mmir.SemanticInterpreter
- getASRSemantic for
-
mmir.ConfigurationManager
- map get(propertyName, defaultValue, useSafeAccess) back to
get(propertyName, useSafeAccess, defaultValue)
the original function will be available via _get(propertyName, useSafeAccess, defaultValue) - map getBoolean(propertyName, defaultValue, useSafeAccess) back to
getBoolean(propertyName, useSafeAccess, defaultValue)
the original function will be available via _getBoolean(propertyName, useSafeAccess, defaultValue) - map getString(propertyName, defaultValue, useSafeAccess) back to
getString(propertyName, useSafeAccess, defaultValue)
the original function will be available via _getString(propertyName, useSafeAccess, defaultValue)
- map get(propertyName, defaultValue, useSafeAccess) back to
-
mmir.Constants
- getPluginsPath (removed) to
mmir.CommonUtils
- getPluginsPath (removed) to
-
mmir.CommonUtils
- loadAllCordovaPlugins (removed) to
mmir.CommonUtils
- setToCompatibilityMode (removed) to
mmir.CommonUtils
- loadAllCordovaPlugins (removed) to
-
mmir.LanguageManager
- setToCompatibilityMode (removed) to
mmir.LanguageManager
- setToCompatibilityMode (removed) to
Name | Type | Description |
---|---|---|
mmir |
mmir | the (core) instance/namespace for MMIR |
Example
mmir.require(['mmirf/core3Compatibility', 'mmirf/core'], function(setCompatibility, mmir){
setCompatibility(mmir);
});
//OR: if mmir-lib modules were require'd in application code, add v3 module-ID aliases first:
mmir.require(['mmirf/core3ModuleIdCompatibility', 'mmirf/core3Compatibility', 'mmirf/core'], function(core3ModuleIdCompatibility, setCompatibility, mmir){
core3ModuleIdCompatibility(mmir.require, window);
setCompatibility(mmir);
});
Requires
- module:SemanticInterpreterCompatibility
Methods
-
async,staticmmir.Core.setToCompatibilityMode3Extension.commonUtils.loadAllCordovaPlugins(pluginsPath, cbFunction){Promise}
-
Load all plugins (i.e. JavaScript interfaces for Cordova v2 / JavaScript-impl. plugins).
Name Type Description pluginsPath
String optional OPTIONAL Path of the plugins which should be loaded, e.g. mmirf/plugins/ If omitted: the default plugin-path is used (see mmir.Core.setToCompatibilityMode3Extension#getPluginsPath
)cbFunction
function optional OPTIONAL The function that should be executed after the plugins are loaded. If the execution of following functions is dependent on the present of plugins, they should be triggered from inside the callback-function Returns:
Deferred.promise (see loadImpl())
-
async,staticmmir.Core.setToCompatibilityMode3Extension.commonUtils.setToCompatibilityMode(success, requireFunction){Promise}
-
Set to "backwards compatibility mode" (for pre version 2.0). This function re-adds deprecated and removed functions and properties to the CommonUtils instance. NOTE that once set to compatibility mode, it cannot be reset to non-compatibility mode. NOTE: Requires jQuery to be present.
Name Type Description success
function optional a callback function that is invoked, after compatibility mode was set (alternatively the returned promise can be used). requireFunction
function optional the require-function that is configured for loading the compatibility module/file. Normally, this would be the function mmir.require
. If omitted, the default (local dependency)require
function will be used. NOTE: this argument is positional, i.e. argumentsuccess
must be present, if you want to specify this argument- Deprecated
- use only for backwards compatibility
Returns:
deferred promise that is resolved, after compatibility mode was set
-
staticmmir.Core.setToCompatibilityMode3Extension.constants.getPluginsPath(){String}
-
Returns a string with the path to the (Cordova v2.x) plugins directory.
Returns:
directory path
-
staticmmir.Core.setToCompatibilityMode3Extension.languageManager.setNextLanguage(){String}
-
Cycles through the available languages.
Returns:
(new) current language
-
async,staticmmir.Core.setToCompatibilityMode3Extension.languageManager.setToCompatibilityMode(success, requireFunction){Promise}
-
Set to "backwards compatibility mode" (for pre version 2.0). This function re-adds deprecated and removed functions and properties to the CommonUtils instance. NOTE that once set to compatibility mode, it cannot be reset to non-compatibility mode. NOTE: Requires jQuery to be present.
Name Type Description success
function optional a callback function that is invoked, after compatibility mode was set (alternatively the returned promise can be used). requireFunction
function optional the require-function that is configured for loading the compatibility module/file. Normally, this would be the function mmir.require
. If omitted, the globalrequire
function will be used. NOTE: this argument is positional, i.e. argumentsuccess
must be present, if you want to specify this argument- Deprecated
- use only for backwards compatibility
Returns:
deferred promise that is resolved, after compatibility mode was set