0.3.2 • Published 5 years ago

xerocross-dstructs v0.3.2

Weekly downloads
18
License
SEE LICENSE IN LI...
Repository
github
Last release
5 years ago

XeroCross DStructs

JavaScript implementations of some classic data structures. There's nothing original here. If there is anything useful here, it will be because of the style in which it was written. The principal author's style is verbose to the point of being didactic.

This is a work under construction.

Why Bother?

Practice. Why not? Who cares?

Exports

SimpleHashMap

    import {SimpleHashMap} from "xerocross-dstructs";
    let hashMap = SimpleHashMap.build(numSlots, hashFunction);
    hashMap.add(key, value); // updates value on duplicate
    hashMap.getValue(key); // returns value or undefined
    hashMap.contains(key); // returns boolean
    hashMap.remove(key);
    hashMap.toList(); // returns JavaScript array of {key, value} objects

License

See the LICENSE.md file for details.

0.3.2

5 years ago

0.3.1

5 years ago

0.3.0

5 years ago

0.2.0

6 years ago