Home | History | Annotate | Download | only in benchmarks

Lines Matching defs:SplayTree

46 var splayTree = null;
76 } while (splayTree.find(key) != null);
78 splayTree.insert(key, payload);
85 splayTree = new SplayTree();
94 var keys = splayTree.exportKeys();
95 splayTree = null;
116 var greatest = splayTree.findGreatestLessThan(key);
117 if (greatest == null) splayTree.remove(key);
118 else splayTree.remove(greatest.key);
131 function SplayTree() {
138 * @type {SplayTree.Node}
141 SplayTree.prototype.root_ = null;
147 SplayTree.prototype.isEmpty = function() {
160 SplayTree.prototype.insert = function(key, value) {
162 this.root_ = new SplayTree.Node(key, value);
171 var node = new SplayTree.Node(key, value);
191 * @return {SplayTree.Node} The removed node.
193 SplayTree.prototype.remove = function(key) {
222 * @return {SplayTree.Node} Node having the specified key.
224 SplayTree.prototype.find = function(key) {
234 * @return {SplayTree.Node} Node having the maximum key value.
236 SplayTree.prototype.findMax = function(opt_startNode) {
249 * @return {SplayTree.Node} Node having the maximum key value that
252 SplayTree.prototype.findGreatestLessThan = function(key) {
274 SplayTree.prototype.exportKeys = function() {
293 SplayTree.prototype.splay_ = function(key) {
303 dummy = left = right = new SplayTree.Node(null, null);
361 SplayTree.Node = function(key, value) {
368 * @type {SplayTree.Node}
370 SplayTree.Node.prototype.left = null;
374 * @type {SplayTree.Node}
376 SplayTree.Node.prototype.right = null;
381 * this SplayTree.Node.
383 * @param {function(SplayTree.Node)} f Visitor function.
386 SplayTree.Node.prototype.traverse_ = function(f) {