_mapCacheClear.js 376 B

1234567891011121314151617181920
  1. var Hash = require('./_Hash'),
  2. ListCache = require('./_ListCache'),
  3. Map = require('./_Map');
  4. /**
  5. * Removes all key-value entries from the map.
  6. *
  7. * @private
  8. * @name clear
  9. * @memberOf MapCache
  10. */
  11. function mapCacheClear() {
  12. this.__data__ = {
  13. 'hash': new Hash,
  14. 'map': new (Map || ListCache),
  15. 'string': new Hash
  16. };
  17. }
  18. module.exports = mapCacheClear;