Timemap.js v.2.0.1

Class TimeMap.loaders.json

Extends:
TimeMap.loaders.remote
Defined in:
json.js

JSON string loader - expects a plain JSON array.

The json_string loader assumes an array of items in plain JSON, with no callback function - this will require a local URL.


TimeMap.init({
    datasets: [
        {
            title: "JSON String Dataset",
            type: "json_string",
            options: {
                url: "mydata.json"    // Must be a local URL
            }
        }
    ],
    // etc...
});

Constructor

TimeMap.loaders.json(options)

Fields

Field
Inherited from TimeMap.loaders.remote
opts :{String}
Object to hold optional settings.
Inherited from TimeMap.loaders.base
scrollTo :{String|Date}
Date to scroll the timeline to on load

Methods

Method
Inherited from TimeMap.loaders.base
cancel()
Cancel the callback function for this loader.
Inherited from TimeMap.loaders.base
getCallback(dataset, callback)
Get a callback function that can be cancelled.
Inherited from TimeMap.loaders.base
getCallbackName(dataset, callback)
Get the name of a callback function that can be cancelled.
Inherited from TimeMap.loaders.remote
load(dataset, callback)
Load function for remote files.
Inherited from TimeMap.loaders.base
parse()
Parser function to turn a string into a JavaScript array
Inherited from TimeMap.loaders.base
Function to call on data object before loading
Inherited from TimeMap.loaders.base
Function to call on a single item data object before loading
Class Detail
TimeMap.loaders.json(options)
Parameters (optional)
options {Object} All options for the loader
options.url {String} URL of JSON file to load
options[...] {mixed} Other options (see loaders.remote)
©2010 Nick Rabinowitz
Documentation generated by JsDoc Toolkit 2.3.2 on Sat Aug 06 2011 13:40:08 GMT-0700 (PDT)