3 Object.defineProperty(exports, "__esModule", {
7 var _timesLimit = require('./timesLimit');
9 var _timesLimit2 = _interopRequireDefault(_timesLimit);
11 var _doLimit = require('./internal/doLimit');
13 var _doLimit2 = _interopRequireDefault(_doLimit);
15 function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
18 * Calls the `iteratee` function `n` times, and accumulates results in the same
19 * manner you would use with [map]{@link module:Collections.map}.
23 * @memberOf module:ControlFlow
25 * @see [async.map]{@link module:Collections.map}
26 * @category Control Flow
27 * @param {number} n - The number of times to run the function.
28 * @param {Function} iteratee - The function to call `n` times. Invoked with the
29 * iteration index and a callback (n, next).
30 * @param {Function} callback - see {@link module:Collections.map}.
33 * // Pretend this is some complicated async factory
34 * var createUser = function(id, callback) {
41 * async.times(5, function(n, next) {
42 * createUser(n, function(err, user) {
45 * }, function(err, users) {
46 * // we should now have 5 users
49 exports.default = (0, _doLimit2.default)(_timesLimit2.default, Infinity);
50 module.exports = exports['default'];