Your IP : 216.73.216.17


Current Path : /etc/kibana/node_modules/optional-js/
Upload File :
Current File : //etc/kibana/node_modules/optional-js/index.js

var Optional = require('./lib/optional.js');

module.exports = {
    empty: function empty() {
        return new Optional();
    },
    of: function of(value) {
        if (value === undefined || value === null) {
            throw new Error('value is not defined');
        }
        return new Optional(value);
    },
    ofNullable: function ofNullable(value) {
        return new Optional(value);
    }
};