Home | History | Annotate | Download | only in js

Lines Matching refs:closure

24  * Enqueues a closure to be executed.
25 * @param {function(function())} closure Closure with a completion callback to
28 AsyncUtil.Queue.prototype.run = function(closure) {
29 this.closures_.push(closure);
35 * Serves the next closure from the queue.
44 // Run the next closure.
46 var closure = this.closures_.shift();
47 closure(this.continue_.bind(this));
64 * Enqueues a closure to be executed after dependencies are completed.
66 * @param {function(function())} closure Closure with a completion callback to
69 * dependencies, then the the closure will be executed immediately.
72 AsyncUtil.Group.prototype.add = function(closure, opt_dependencies, opt_name) {
77 closure: closure,
125 task.closure(this.finish_.bind(this, task));
142 * Aggregates consecutive calls and executes the closure only once instead of
144 * consecutive ones are aggregated and the closure is called only once once
147 * @param {function()} closure Closure to be aggregated.
152 AsyncUtil.Aggregation = function(closure, opt_delay) {
163 this.closure_ = closure;
179 * Runs a closure. Skips consecutive calls. The first call is called