Useful for calculating ISO8601 durations when submitting statements that require durations. calculateISO8601Duration is a static method of the XAPI Class.
Gets the launch data if the module was launched as a TinCan module. getTinCanLaunchData is a static method of the XAPI Class.
getSearchQueryParamsAsObject
Converts search query parameters from a string into an object. getSearchQueryParamsAsObject is a static method of the XAPI Object. Used in getTinCanLaunchData and getXAPILaunchData. If any JSON is detected an attempt is made to parse it, else properties are returned as decoded strings.
For backwards compatibility with some LMS/LRS (SCORM Cloud), if an actor property is found containing string arrays for name, mbox and account these are coerced into objects containing the first array entry only. Also if the property is account the first array object is converted from: