SuperHash
HashMap that supports using one or more keys of any type*
Hash keys are generated using multikey-hash
Installation
$ npm install superhash
Examples
var SuperHash = require('superhash');
var hashMap = new SuperHash();
var data = 'value';
Single key:
hashMap.set(/.*/g, data);
hashMap.get("/.*/g");
hashMap.get(/.*/g);
hashMap.delete(/.*/g);
Multiple keys:
hashMap.set(1,{ name: 'foo' }, true, data);
hashMap.get(1,{ name: 'foo' }, "true");
hashMap.get(1,{ name: 'foo' }, true);
hashMap.delete(1,{ name: 'foo' }, true);
API
See API.md
FAQ
What types of keys can be used?
Any primitive or mutable object can be used as a key.
Who named this module?
@nik
LICENSE
MIT