Javascript equivalent of the C++ STL containers