{"name":"batch","version":"0.0.2","description":"Simple async batch","keywords":[],"author":{"name":"TJ Holowaychuk","email":"tj@vision-media.ca"},"dependencies":{"mocha":"*","should":"*"},"main":"index","engines":{"node":"*"},"_npmUser":{"name":"tjholowaychuk","email":"tj@vision-media.ca"},"_id":"batch@0.0.2","devDependencies":{},"_engineSupported":true,"_npmVersion":"1.0.106","_nodeVersion":"v0.6.10","_defaultsLoaded":true,"dist":{"shasum":"fc558c82ded76cd8ddf049d2ba065f352d185f9c","tarball":"http://registry-npm.ywwl.com/batch/download/batch-0.0.2.tgz","integrity":"sha512-JjQAOE/kffwXAVf9hcTx7VeObfz/PQTWgWwaNl4/Tu9ehVJE1/mC0VTIHizz95bgjfCFBBpvBuTUDTnICakIAw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCE7Bqu+y6hBDUWxP9syoJdRpfQBhAyffyeYq/MrMSiXgIgL+zZB0iRkfoVgfF5bDf943OuPFgabV2F490+vhMwjIY="}],"size":10240,"noattachment":false,"key":"/batch/-/batch-0.0.2.tgz"},"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":1329094221813,"_cnpm_publish_time":1329094221813,"dist-tags":{"latest":"0.6.1"}}