1 | import hashClear from './_hashClear.js';
|
2 | import hashDelete from './_hashDelete.js';
|
3 | import hashGet from './_hashGet.js';
|
4 | import hashHas from './_hashHas.js';
|
5 | import hashSet from './_hashSet.js';
|
6 |
|
7 |
|
8 |
|
9 |
|
10 |
|
11 |
|
12 |
|
13 |
|
14 | function Hash(entries) {
|
15 | var index = -1,
|
16 | length = entries == null ? 0 : entries.length;
|
17 |
|
18 | this.clear();
|
19 | while (++index < length) {
|
20 | var entry = entries[index];
|
21 | this.set(entry[0], entry[1]);
|
22 | }
|
23 | }
|
24 |
|
25 |
|
26 | Hash.prototype.clear = hashClear;
|
27 | Hash.prototype['delete'] = hashDelete;
|
28 | Hash.prototype.get = hashGet;
|
29 | Hash.prototype.has = hashHas;
|
30 | Hash.prototype.set = hashSet;
|
31 |
|
32 | export default Hash;
|