All Downloads are FREE. Search and download functionalities are using the official Maven repository.

Lib.robot.htmldata.common.storage.js Maven / Gradle / Ivy

There is a newer version: 2.0.5
Show newest version
storage = function () {

    var prefix = 'robot-framework-';

    function init(user) {
        prefix += user + '-';
    }

    function get(name, defaultValue) {
        if (!localStorage)
            return defaultValue;
        var value = localStorage[prefix + name];
        if (typeof value === 'undefined')
            return defaultValue;
        return value;
    }

    function set(name, value) {
        if (localStorage)
            localStorage[prefix + name] = value;
    }

    return {init: init, get: get, set: set};
}();




© 2015 - 2025 Weber Informatics LLC | Privacy Policy