Sha256: ef72b05f27b810feb101850db8bb6c7215996b2396a807f78d67d9ed8656af8c

Contents?: true

Size: 624 Bytes

Versions: 26

Compression:

Stored size: 624 Bytes

Contents

var MapCache = require('./_MapCache'),
    setCacheAdd = require('./_setCacheAdd'),
    setCacheHas = require('./_setCacheHas');

/**
 *
 * Creates an array cache object to store unique values.
 *
 * @private
 * @constructor
 * @param {Array} [values] The values to cache.
 */
function SetCache(values) {
  var index = -1,
      length = values ? values.length : 0;

  this.__data__ = new MapCache;
  while (++index < length) {
    this.add(values[index]);
  }
}

// Add methods to `SetCache`.
SetCache.prototype.add = SetCache.prototype.push = setCacheAdd;
SetCache.prototype.has = setCacheHas;

module.exports = SetCache;

Version data entries

26 entries across 5 versions & 3 rubygems

Version Path
babel-schmooze-sprockets-0.1.1 node_modules/babel-register/node_modules/lodash/_SetCache.js
babel-schmooze-sprockets-0.1.1 node_modules/babel-template/node_modules/lodash/_SetCache.js
babel-schmooze-sprockets-0.1.1 node_modules/babel-plugin-transform-es2015-function-name/node_modules/lodash/_SetCache.js
babel-schmooze-sprockets-0.1.1 node_modules/babel-generator/node_modules/lodash/_SetCache.js
babel-schmooze-sprockets-0.1.1 node_modules/babel-helper-call-delegate/node_modules/lodash/_SetCache.js
babel-schmooze-sprockets-0.1.1 node_modules/babel-helper-define-map/node_modules/lodash/_SetCache.js