{"_id":"length-prefixed-stream","_rev":"480791","name":"length-prefixed-stream","description":"Streaming length prefixed buffers","dist-tags":{"latest":"2.0.0"},"maintainers":[{"name":"mafintosh","email":""}],"time":{"modified":"2021-08-05T09:35:23.000Z","created":"2014-08-16T14:13:13.429Z","2.0.0":"2019-02-04T09:31:21.889Z","1.6.0":"2018-06-21T08:26:16.199Z","1.5.2":"2018-03-23T02:24:53.185Z","1.5.1":"2016-11-04T19:51:31.574Z","1.5.0":"2016-03-05T17:06:58.750Z","1.4.0":"2015-08-12T23:29:03.438Z","1.3.2":"2015-08-06T14:01:24.441Z","1.3.1":"2015-08-06T13:02:23.540Z","1.3.0":"2015-06-16T20:11:57.239Z","1.2.0":"2015-05-15T21:29:07.411Z","1.1.0":"2015-03-06T23:54:39.269Z","1.0.1":"2014-10-09T01:45:02.905Z","1.0.0":"2014-08-16T14:13:13.429Z"},"users":{},"author":{"name":"Mathias Buus"},"repository":{"type":"git","url":"git+https://github.com/mafintosh/length-prefixed-stream.git"},"versions":{"2.0.0":{"name":"length-prefixed-stream","version":"2.0.0","description":"Streaming length prefixed buffers","main":"index.js","dependencies":{"inherits":"^2.0.3","readable-stream":"^3.1.1","varint":"^5.0.0"},"devDependencies":{"concat-stream":"^2.0.0","from2":"^2.3.0","standard":"^12.0.1","tape":"^4.9.2","through2":"^3.0.0"},"scripts":{"test":"standard && tape test.js"},"repository":{"type":"git","url":"git+https://github.com/mafintosh/length-prefixed-stream.git"},"keywords":["varint","length","prefixed","stream","streaming"],"author":{"name":"Mathias Buus"},"license":"MIT","bugs":{"url":"https://github.com/mafintosh/length-prefixed-stream/issues"},"homepage":"https://github.com/mafintosh/length-prefixed-stream","gitHead":"e3a4af9af75279d5495beee74489b1245d54f32e","_id":"length-prefixed-stream@2.0.0","_npmVersion":"6.4.1","_nodeVersion":"10.15.1","_npmUser":{"name":"mafintosh","email":"mathiasbuus@gmail.com"},"dist":{"shasum":"16e603c97aefb46f43ae4b5d22f1734ecd14ffce","size":3761,"noattachment":false,"key":"/length-prefixed-stream/-/length-prefixed-stream-2.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/length-prefixed-stream/download/length-prefixed-stream-2.0.0.tgz"},"maintainers":[{"name":"mafintosh","email":""}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/length-prefixed-stream_2.0.0_1549272681794_0.25290754793480774"},"_hasShrinkwrap":false,"publish_time":1549272681889,"_cnpm_publish_time":1549272681889},"1.6.0":{"name":"length-prefixed-stream","version":"1.6.0","description":"Streaming length prefixed buffers","main":"index.js","dependencies":{"buffer-alloc-unsafe":"^1.0.0","readable-stream":"^2.0.0","varint":"^5.0.0"},"devDependencies":{"buffer-from":"^1.0.0","concat-stream":"^1.4.6","from2":"^2.1.0","standard":"^6.0.7","tape":"^2.14.0","through2":"^0.6.1"},"scripts":{"test":"standard && tape test.js"},"repository":{"type":"git","url":"git+https://github.com/mafintosh/length-prefixed-stream.git"},"keywords":["varint","length","prefixed","stream","streaming"],"author":{"name":"Mathias Buus"},"license":"MIT","bugs":{"url":"https://github.com/mafintosh/length-prefixed-stream/issues"},"homepage":"https://github.com/mafintosh/length-prefixed-stream","gitHead":"38fbbadc9d854ace430b6b8c57cbacd925d5a7aa","_id":"length-prefixed-stream@1.6.0","_npmVersion":"6.1.0","_nodeVersion":"10.3.0","_npmUser":{"name":"mafintosh","email":"mathiasbuus@gmail.com"},"dist":{"shasum":"6aeeecf38a337172ea0472250e90f5e15b8b2334","size":3779,"noattachment":false,"key":"/length-prefixed-stream/-/length-prefixed-stream-1.6.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/length-prefixed-stream/download/length-prefixed-stream-1.6.0.tgz"},"maintainers":[{"name":"mafintosh","email":""}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/length-prefixed-stream_1.6.0_1529569576127_0.06559820301792252"},"_hasShrinkwrap":false,"publish_time":1529569576199,"_cnpm_publish_time":1529569576199},"1.5.2":{"name":"length-prefixed-stream","version":"1.5.2","description":"Streaming length prefixed buffers","main":"index.js","dependencies":{"buffer-alloc-unsafe":"^1.0.0","readable-stream":"^2.0.0","varint":"^5.0.0"},"devDependencies":{"buffer-from":"^1.0.0","concat-stream":"^1.4.6","from2":"^2.1.0","standard":"^6.0.7","tape":"^2.14.0","through2":"^0.6.1"},"scripts":{"test":"standard && tape test.js"},"repository":{"type":"git","url":"git+https://github.com/mafintosh/length-prefixed-stream.git"},"keywords":["varint","length","prefixed","stream","streaming"],"author":{"name":"Mathias Buus"},"license":"MIT","bugs":{"url":"https://github.com/mafintosh/length-prefixed-stream/issues"},"homepage":"https://github.com/mafintosh/length-prefixed-stream","gitHead":"59e749f73292be2d4080e9dc8cbfea6b31ea1489","_id":"length-prefixed-stream@1.5.2","_npmVersion":"5.6.0","_nodeVersion":"9.7.1","_npmUser":{"name":"mafintosh","email":"mathiasbuus@gmail.com"},"dist":{"shasum":"269b29ff76324361727447f1bfacb762e6965a8f","size":3738,"noattachment":false,"key":"/length-prefixed-stream/-/length-prefixed-stream-1.5.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/length-prefixed-stream/download/length-prefixed-stream-1.5.2.tgz"},"maintainers":[{"name":"mafintosh","email":""}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/length-prefixed-stream_1.5.2_1521771893124_0.6713791624510206"},"_hasShrinkwrap":false,"publish_time":1521771893185,"_cnpm_publish_time":1521771893185},"1.5.1":{"name":"length-prefixed-stream","version":"1.5.1","description":"Streaming length prefixed buffers","main":"index.js","dependencies":{"readable-stream":"^2.0.0","varint":"^5.0.0"},"devDependencies":{"concat-stream":"^1.4.6","from2":"^2.1.0","standard":"^6.0.7","tape":"^2.14.0","through2":"^0.6.1"},"scripts":{"test":"standard && tape test.js"},"repository":{"type":"git","url":"https://github.com/mafintosh/length-prefixed-stream"},"keywords":["varint","length","prefixed","stream","streaming"],"author":{"name":"Mathias Buus"},"license":"MIT","bugs":{"url":"https://github.com/mafintosh/length-prefixed-stream/issues"},"homepage":"https://github.com/mafintosh/length-prefixed-stream","gitHead":"9634ad4c841e233085e286dd031a05d57b8aa394","_id":"length-prefixed-stream@1.5.1","_shasum":"99eaf51672dddefbfdd8881ee7b7b7df35d1ed73","_from":".","_npmVersion":"2.15.9","_nodeVersion":"4.6.1","_npmUser":{"name":"mafintosh","email":"mathiasbuus@gmail.com"},"dist":{"shasum":"99eaf51672dddefbfdd8881ee7b7b7df35d1ed73","size":3764,"noattachment":false,"key":"/length-prefixed-stream/-/length-prefixed-stream-1.5.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/length-prefixed-stream/download/length-prefixed-stream-1.5.1.tgz"},"maintainers":[{"name":"mafintosh","email":""}],"_npmOperationalInternal":{"host":"packages-18-east.internal.npmjs.com","tmp":"tmp/length-prefixed-stream-1.5.1.tgz_1478289089674_0.6161962982732803"},"directories":{},"publish_time":1478289091574,"_cnpm_publish_time":1478289091574,"_hasShrinkwrap":false},"1.5.0":{"name":"length-prefixed-stream","version":"1.5.0","description":"Streaming length prefixed buffers","main":"index.js","dependencies":{"readable-stream":"^2.0.0","varint":"^4.0.0"},"devDependencies":{"concat-stream":"^1.4.6","from2":"^2.1.0","standard":"^6.0.7","tape":"^2.14.0","through2":"^0.6.1"},"scripts":{"test":"standard && tape test.js"},"repository":{"type":"git","url":"https://github.com/mafintosh/length-prefixed-stream"},"keywords":["varint","length","prefixed","stream","streaming"],"author":{"name":"Mathias Buus"},"license":"MIT","bugs":{"url":"https://github.com/mafintosh/length-prefixed-stream/issues"},"homepage":"https://github.com/mafintosh/length-prefixed-stream","gitHead":"b4e7ea6275e032fb3a2d346f1cf39870d4288c94","_id":"length-prefixed-stream@1.5.0","_shasum":"2801e7d05e7f5205c497b01843f1d006cdffceb1","_from":".","_npmVersion":"2.14.12","_nodeVersion":"4.3.1","_npmUser":{"name":"mafintosh","email":"mathiasbuus@gmail.com"},"dist":{"shasum":"2801e7d05e7f5205c497b01843f1d006cdffceb1","size":3775,"noattachment":false,"key":"/length-prefixed-stream/-/length-prefixed-stream-1.5.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/length-prefixed-stream/download/length-prefixed-stream-1.5.0.tgz"},"maintainers":[{"name":"mafintosh","email":""}],"_npmOperationalInternal":{"host":"packages-13-west.internal.npmjs.com","tmp":"tmp/length-prefixed-stream-1.5.0.tgz_1457197617200_0.9325092516373843"},"directories":{},"publish_time":1457197618750,"_cnpm_publish_time":1457197618750,"_hasShrinkwrap":false},"1.4.0":{"name":"length-prefixed-stream","version":"1.4.0","description":"Streaming length prefixed buffers","main":"index.js","dependencies":{"readable-stream":"^2.0.0","varint":"^4.0.0"},"devDependencies":{"concat-stream":"^1.4.6","from2":"^2.1.0","tape":"^2.14.0","through2":"^0.6.1"},"scripts":{"test":"tape test.js"},"repository":{"type":"git","url":"git+https://github.com/mafintosh/length-prefixed-stream.git"},"keywords":["varint","length","prefixed","stream","streaming"],"author":{"name":"Mathias Buus"},"license":"MIT","bugs":{"url":"https://github.com/mafintosh/length-prefixed-stream/issues"},"homepage":"https://github.com/mafintosh/length-prefixed-stream","gitHead":"13718d72608c12e16a297ddbd9a04d8e5539c337","_id":"length-prefixed-stream@1.4.0","_shasum":"fc61abd08527923b16153308da2075c67e090892","_from":".","_npmVersion":"2.13.4","_nodeVersion":"2.5.0","_npmUser":{"name":"mafintosh","email":"mathiasbuus@gmail.com"},"dist":{"shasum":"fc61abd08527923b16153308da2075c67e090892","size":3586,"noattachment":false,"key":"/length-prefixed-stream/-/length-prefixed-stream-1.4.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/length-prefixed-stream/download/length-prefixed-stream-1.4.0.tgz"},"maintainers":[{"name":"mafintosh","email":""}],"directories":{},"publish_time":1439422143438,"_cnpm_publish_time":1439422143438,"_hasShrinkwrap":false},"1.3.2":{"name":"length-prefixed-stream","version":"1.3.2","description":"Streaming length prefixed buffers","main":"index.js","dependencies":{"readable-stream":"^2.0.0","varint":"^4.0.0"},"devDependencies":{"concat-stream":"^1.4.6","from2":"^2.1.0","tape":"^2.14.0","through2":"^0.6.1"},"scripts":{"test":"tape test.js"},"repository":{"type":"git","url":"https://github.com/mafintosh/length-prefixed-stream"},"keywords":["varint","length","prefixed","stream","streaming"],"author":{"name":"Mathias Buus"},"license":"MIT","bugs":{"url":"https://github.com/mafintosh/length-prefixed-stream/issues"},"homepage":"https://github.com/mafintosh/length-prefixed-stream","gitHead":"adcbee57fbf303f97b548c826a08d6a0618cd507","_id":"length-prefixed-stream@1.3.2","_shasum":"cced33cc4416f3c546c9545cfb4b90b7f2cfef33","_from":".","_npmVersion":"2.13.3","_nodeVersion":"3.0.0","_npmUser":{"name":"mafintosh","email":"mathiasbuus@gmail.com"},"dist":{"shasum":"cced33cc4416f3c546c9545cfb4b90b7f2cfef33","size":3349,"noattachment":false,"key":"/length-prefixed-stream/-/length-prefixed-stream-1.3.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/length-prefixed-stream/download/length-prefixed-stream-1.3.2.tgz"},"maintainers":[{"name":"mafintosh","email":""}],"directories":{},"publish_time":1438869684441,"_cnpm_publish_time":1438869684441,"_hasShrinkwrap":false},"1.3.1":{"name":"length-prefixed-stream","version":"1.3.1","description":"Streaming length prefixed buffers","main":"index.js","dependencies":{"readable-stream":"^2.0.0","varint":"^4.0.0"},"devDependencies":{"concat-stream":"^1.4.6","tape":"^2.14.0","through2":"^0.6.1"},"scripts":{"test":"tape test.js"},"repository":{"type":"git","url":"https://github.com/mafintosh/length-prefixed-stream"},"keywords":["varint","length","prefixed","stream","streaming"],"author":{"name":"Mathias Buus"},"license":"MIT","bugs":{"url":"https://github.com/mafintosh/length-prefixed-stream/issues"},"homepage":"https://github.com/mafintosh/length-prefixed-stream","gitHead":"9ad4d0aa29ac11eb0864a626593ded8eeaf443e6","_id":"length-prefixed-stream@1.3.1","_shasum":"bda3815c1de9213cc39fd505f4715c31d5770212","_from":".","_npmVersion":"2.13.3","_nodeVersion":"3.0.0","_npmUser":{"name":"mafintosh","email":"mathiasbuus@gmail.com"},"dist":{"shasum":"bda3815c1de9213cc39fd505f4715c31d5770212","size":3226,"noattachment":false,"key":"/length-prefixed-stream/-/length-prefixed-stream-1.3.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/length-prefixed-stream/download/length-prefixed-stream-1.3.1.tgz"},"maintainers":[{"name":"mafintosh","email":""}],"directories":{},"publish_time":1438866143540,"_cnpm_publish_time":1438866143540,"_hasShrinkwrap":false},"1.3.0":{"name":"length-prefixed-stream","version":"1.3.0","description":"Streaming length prefixed buffers","main":"index.js","dependencies":{"readable-stream":"^2.0.0","varint":"^4.0.0"},"devDependencies":{"concat-stream":"^1.4.6","tape":"^2.14.0","through2":"^0.6.1"},"scripts":{"test":"tape test.js"},"repository":{"type":"git","url":"git+https://github.com/mafintosh/length-prefixed-stream.git"},"keywords":["varint","length","prefixed","stream","streaming"],"author":{"name":"Mathias Buus"},"license":"MIT","bugs":{"url":"https://github.com/mafintosh/length-prefixed-stream/issues"},"homepage":"https://github.com/mafintosh/length-prefixed-stream","gitHead":"309635961eaa5c85bf8443a86364d395b0a3d957","_id":"length-prefixed-stream@1.3.0","_shasum":"ca82d60050900d0851052cc3cdfe3360f2df11c8","_from":".","_npmVersion":"2.11.0","_nodeVersion":"2.2.1","_npmUser":{"name":"mafintosh","email":"mathiasbuus@gmail.com"},"dist":{"shasum":"ca82d60050900d0851052cc3cdfe3360f2df11c8","size":3106,"noattachment":false,"key":"/length-prefixed-stream/-/length-prefixed-stream-1.3.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/length-prefixed-stream/download/length-prefixed-stream-1.3.0.tgz"},"maintainers":[{"name":"mafintosh","email":""}],"directories":{},"publish_time":1434485517239,"_cnpm_publish_time":1434485517239,"_hasShrinkwrap":false},"1.2.0":{"name":"length-prefixed-stream","version":"1.2.0","description":"Streaming length prefixed buffers","main":"index.js","dependencies":{"readable-stream":"^1.1.13","varint":"^3.0.1"},"devDependencies":{"concat-stream":"^1.4.6","tape":"^2.14.0","through2":"^0.6.1"},"scripts":{"test":"tape test.js"},"repository":{"type":"git","url":"https://github.com/mafintosh/length-prefixed-stream"},"keywords":["varint","length","prefixed","stream","streaming"],"author":{"name":"Mathias Buus"},"license":"MIT","bugs":{"url":"https://github.com/mafintosh/length-prefixed-stream/issues"},"homepage":"https://github.com/mafintosh/length-prefixed-stream","gitHead":"9915057ec3f4d7f4d55ceb163d846027bf25ea7f","_id":"length-prefixed-stream@1.2.0","_shasum":"c0af9af340783497a1accdb39b9be2e903c49fcb","_from":".","_npmVersion":"2.9.0","_nodeVersion":"2.0.1","_npmUser":{"name":"mafintosh","email":"mathiasbuus@gmail.com"},"maintainers":[{"name":"mafintosh","email":""}],"dist":{"shasum":"c0af9af340783497a1accdb39b9be2e903c49fcb","size":3132,"noattachment":false,"key":"/length-prefixed-stream/-/length-prefixed-stream-1.2.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/length-prefixed-stream/download/length-prefixed-stream-1.2.0.tgz"},"directories":{},"publish_time":1431725347411,"_cnpm_publish_time":1431725347411,"_hasShrinkwrap":false},"1.1.0":{"name":"length-prefixed-stream","version":"1.1.0","description":"Streaming length prefixed buffers","main":"index.js","dependencies":{"readable-stream":"^1.0.33","varint":"^3.0.1"},"devDependencies":{"concat-stream":"^1.4.6","tape":"^2.14.0","through2":"^0.6.1"},"scripts":{"test":"tape test.js"},"repository":{"type":"git","url":"https://github.com/mafintosh/length-prefixed-stream"},"keywords":["varint","length","prefixed","stream","streaming"],"author":{"name":"Mathias Buus"},"license":"MIT","bugs":{"url":"https://github.com/mafintosh/length-prefixed-stream/issues"},"homepage":"https://github.com/mafintosh/length-prefixed-stream","gitHead":"38ba5fc886ab56306790221c8d03ded2d21dec24","_id":"length-prefixed-stream@1.1.0","_shasum":"a88834cf383f458151c158933a51c5560fa30525","_from":".","_npmVersion":"2.7.0","_nodeVersion":"1.5.0","_npmUser":{"name":"mafintosh","email":"mathiasbuus@gmail.com"},"maintainers":[{"name":"mafintosh","email":""}],"dist":{"shasum":"a88834cf383f458151c158933a51c5560fa30525","size":2799,"noattachment":false,"key":"/length-prefixed-stream/-/length-prefixed-stream-1.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/length-prefixed-stream/download/length-prefixed-stream-1.1.0.tgz"},"directories":{},"publish_time":1425686079269,"_cnpm_publish_time":1425686079269,"_hasShrinkwrap":false},"1.0.1":{"name":"length-prefixed-stream","version":"1.0.1","description":"Streaming length prefixed buffers","main":"index.js","dependencies":{"varint":"^3.0.1"},"devDependencies":{"concat-stream":"^1.4.6","tape":"^2.14.0","through2":"^0.6.1"},"scripts":{"test":"tape test.js"},"repository":{"type":"git","url":"https://github.com/mafintosh/length-prefixed-stream"},"keywords":["varint","length","prefixed","stream","streaming"],"author":{"name":"Mathias Buus"},"license":"MIT","bugs":{"url":"https://github.com/mafintosh/length-prefixed-stream/issues"},"homepage":"https://github.com/mafintosh/length-prefixed-stream","gitHead":"894c9db9e5635b5faf5b21f6b6529afd99130d9a","_id":"length-prefixed-stream@1.0.1","_shasum":"67438f19c0e710fa33605a5ed2f3cd8a12035e61","_from":".","_npmVersion":"2.0.0","_npmUser":{"name":"mafintosh","email":"mathiasbuus@gmail.com"},"maintainers":[{"name":"mafintosh","email":""}],"dist":{"shasum":"67438f19c0e710fa33605a5ed2f3cd8a12035e61","size":2808,"noattachment":false,"key":"/length-prefixed-stream/-/length-prefixed-stream-1.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/length-prefixed-stream/download/length-prefixed-stream-1.0.1.tgz"},"directories":{},"publish_time":1412819102905,"_cnpm_publish_time":1412819102905,"_hasShrinkwrap":false},"1.0.0":{"name":"length-prefixed-stream","version":"1.0.0","description":"Streaming length prefixed buffers","main":"index.js","dependencies":{"varint":"^3.0.1"},"devDependencies":{"tape":"^2.14.0","through2":"^0.6.1"},"scripts":{"test":"tape test.js"},"repository":{"type":"git","url":"https://github.com/mafintosh/length-prefixed-stream"},"keywords":["varint","length","prefixed","stream","streaming"],"author":{"name":"Mathias Buus"},"license":"MIT","bugs":{"url":"https://github.com/mafintosh/length-prefixed-stream/issues"},"homepage":"https://github.com/mafintosh/length-prefixed-stream","gitHead":"eb0b5b40f201be22f382f3516da317752172c129","_id":"length-prefixed-stream@1.0.0","_shasum":"a95bf4ee986a40aad7326e55005327e71db6581b","_from":".","_npmVersion":"1.4.23","_npmUser":{"name":"mafintosh","email":"mathiasbuus@gmail.com"},"maintainers":[{"name":"mafintosh","email":""}],"dist":{"shasum":"a95bf4ee986a40aad7326e55005327e71db6581b","size":2595,"noattachment":false,"key":"/length-prefixed-stream/-/length-prefixed-stream-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/length-prefixed-stream/download/length-prefixed-stream-1.0.0.tgz"},"directories":{},"publish_time":1408198393429,"_cnpm_publish_time":1408198393429,"_hasShrinkwrap":false}},"readme":"# length-prefixed-stream\n\nStreaming equivalent of [length-prefixed-message](https://github.com/sorribas/length-prefixed-message).\nThis module allow you to send buffers with a varint length prefix to ensure that they will arrive unpartioned\n\n```\nnpm install length-prefixed-stream\n```\n\n[![build status](https://travis-ci.org/mafintosh/length-prefixed-stream.svg?branch=master)](https://travis-ci.org/mafintosh/length-prefixed-stream)\n\n## Usage\n\n``` js\nvar lpstream = require('length-prefixed-stream')\n\nvar encode = lpstream.encode() // create an encode stream to send data\nvar decode = lpstream.decode() // create an decode stream to receive data\n\nencode.write('hello world') // send \"hello world\"\n\ndecode.on('data', function(data) {\n  console.log(data.toString()) // will always print \"hello world\"\n})\n\nencode.pipe(decode) // for testing just pipe to our selves\n```\n\n## API\n\n#### `transformStream = lpstream.encode()`\n\nCreates a new encoder transform stream.\n\n#### `transformStream = lpstream.decode()`\n\nCreates a new decoder transform stream.\n\n## License\n\nMIT\n","_attachments":{},"homepage":"https://github.com/mafintosh/length-prefixed-stream","bugs":{"url":"https://github.com/mafintosh/length-prefixed-stream/issues"},"license":"MIT"}