{"name":"batch","version":"0.4.0","description":"Simple async batch","author":{"name":"TJ Holowaychuk","email":"tj@vision-media.ca"},"devDependencies":{"mocha":"*","should":"*"},"main":"index","_id":"batch@0.4.0","dist":{"shasum":"bffe40bc117b73942da155bc77d8a36a21a6ac58","tarball":"http://registry-npm.ywwl.com/batch/download/batch-0.4.0.tgz","integrity":"sha512-Mv7idM4imIz9gpscfjHpZmdkI/1zhhyd4+WQTDsOwUmHT9jKVkATgHNc5GbVcyQD6z3dv+C26MVhgY7ojhCyMQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICVOkkWOMTYySunaIyiefQDAPIz/MpdpxZaZUap+AADnAiBerp0qeRc5J8VOWTIIAY+zuz7ell8ZYSpcAAopv6u88A=="}],"size":2809,"noattachment":false,"key":"/batch/-/batch-0.4.0.tgz"},"_from":".","_npmVersion":"1.2.21","_npmUser":{"name":"tjholowaychuk","email":"tj@vision-media.ca"},"maintainers":[{"name":"tjholowaychuk","email":"tj@vision-media.ca"}],"directories":{},"readme":"\n# batch\n\n  Simple async batch with concurrency control and progress reporting.\n\n## Installation\n\n```\n$ npm install batch\n```\n\n## API\n\n```js\nvar Batch = require('batch')\n  , batch = new Batch;\n\nbatch.concurrency(4);\n\nids.forEach(function(id){\n  batch.push(function(done){\n    User.get(id, done);\n  });\n});\n\nbatch.on('progress', function(e){\n\n});\n\nbatch.end(function(err, users){\n\n});\n```\n\n### Progress events\n\n  Contain the \"job\" index, response value, duration information, and completion data.\n\n```\n{ index: 1,\n  value: 'bar',\n  pending: 2,\n  total: 3,\n  complete: 2,\n  percent: 66,\n  start: Thu Oct 04 2012 12:25:53 GMT-0700 (PDT),\n  end: Thu Oct 04 2012 12:25:53 GMT-0700 (PDT),\n  duration: 0 }\n```\n\n## License\n\n[MIT](LICENSE)\n","publish_time":1370491343107,"_cnpm_publish_time":1370491343107,"dist-tags":{"latest":"0.6.1"}}