{"_id":"reduplexer","_rev":"2994221","name":"reduplexer","description":"Another Stream2 duplexer","dist-tags":{"latest":"1.1.0"},"maintainers":[{"name":"matteo.collina","email":""}],"time":{"modified":"2023-08-28T09:19:21.000Z","created":"2014-03-13T08:38:13.288Z","1.1.0":"2014-12-01T11:41:40.837Z","1.0.0":"2014-10-15T06:23:16.567Z","0.0.7":"2014-08-20T09:37:31.489Z","0.0.6":"2014-07-30T08:01:56.042Z","0.0.5":"2014-07-28T11:26:18.879Z","0.0.4":"2014-07-28T10:05:35.109Z","0.0.3":"2014-07-28T09:48:38.013Z","0.0.2":"2014-03-13T10:36:53.554Z","0.0.1":"2014-03-13T08:38:13.288Z"},"users":{},"author":{"name":"Matteo Collina","email":"hello@matteocollina.com"},"repository":{"type":"git","url":"https://github.com/mcollina/reduplexer.git"},"versions":{"1.1.0":{"name":"reduplexer","version":"1.1.0","description":"Another Stream2 duplexer","main":"index.js","scripts":{"test":"node test.js | faucet","test-browser":"zuul --local 8080 --ui tape -- test.js"},"pre-commit":["test"],"website":"https://github.com/mcollina/reduplexer","repository":{"type":"git","url":"https://github.com/mcollina/reduplexer.git"},"bugs":{"url":"http://github.com/mcollina/reduplexer/issues"},"author":{"name":"Matteo Collina","email":"hello@matteocollina.com"},"license":"ISC","devDependencies":{"faucet":"0.0.1","pre-commit":"0.0.9","tape":"^2.14.0","zuul":"^1.10.1"},"dependencies":{"inherits":"^2.0.1","readable-stream":"~1.0.26-2"},"keywords":["duplexer","streams","streams2","duplex","readable","writable"],"gitHead":"b1325a44741eb70e4f5da7b0a8509cd870a42879","homepage":"https://github.com/mcollina/reduplexer","_id":"reduplexer@1.1.0","_shasum":"7dfed18a679e749c1d7ad36de01acb515f08e140","_from":".","_npmVersion":"2.1.9","_nodeVersion":"0.10.33","_npmUser":{"name":"matteo.collina","email":"hello@matteocollina.com"},"maintainers":[{"name":"matteo.collina","email":""}],"dist":{"shasum":"7dfed18a679e749c1d7ad36de01acb515f08e140","size":4018,"noattachment":false,"key":"/reduplexer/-/reduplexer-1.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/reduplexer/download/reduplexer-1.1.0.tgz"},"directories":{},"publish_time":1417434100837,"_hasShrinkwrap":false,"_cnpm_publish_time":1417434100837,"_cnpmcore_publish_time":"2021-12-16T16:03:25.236Z"},"1.0.0":{"name":"reduplexer","version":"1.0.0","description":"Another Stream2 duplexer","main":"index.js","scripts":{"test":"node test.js | faucet","test-browser":"zuul --local 8080 --ui tape -- test.js"},"pre-commit":["test"],"website":"https://github.com/mcollina/reduplexer","repository":{"type":"git","url":"https://github.com/mcollina/reduplexer.git"},"bugs":{"url":"http://github.com/mcollina/reduplexer/issues"},"author":{"name":"Matteo Collina","email":"hello@matteocollina.com"},"license":"ISC","devDependencies":{"faucet":"0.0.1","pre-commit":"0.0.9","tape":"^2.14.0","zuul":"^1.10.1"},"dependencies":{"inherits":"^2.0.1","readable-stream":"~1.0.26-2"},"keywords":["duplexer","streams","streams2","duplex","readable","writable"],"gitHead":"5486fac37483e58bf0666f5e57be85013868fe8b","homepage":"https://github.com/mcollina/reduplexer","_id":"reduplexer@1.0.0","_shasum":"b3362a79277981b2761db3af38d8e3e02654adff","_from":".","_npmVersion":"1.4.28","_npmUser":{"name":"matteo.collina","email":"hello@matteocollina.com"},"maintainers":[{"name":"matteo.collina","email":""}],"dist":{"shasum":"b3362a79277981b2761db3af38d8e3e02654adff","size":3846,"noattachment":false,"key":"/reduplexer/-/reduplexer-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/reduplexer/download/reduplexer-1.0.0.tgz"},"directories":{},"publish_time":1413354196567,"_hasShrinkwrap":false,"_cnpm_publish_time":1413354196567,"_cnpmcore_publish_time":"2021-12-16T16:03:25.665Z"},"0.0.7":{"name":"reduplexer","version":"0.0.7","description":"Another Stream2 duplexer","main":"index.js","scripts":{"test":"node test.js | faucet","test-browser":"zuul --local 8080 --ui tape -- test.js"},"pre-commit":["test"],"website":"https://github.com/mcollina/reduplexer","repository":{"type":"git","url":"https://github.com/mcollina/reduplexer.git"},"bugs":{"url":"http://github.com/mcollina/reduplexer/issues"},"author":{"name":"Matteo Collina","email":"hello@matteocollina.com"},"license":"ISC","devDependencies":{"faucet":"0.0.1","pre-commit":"0.0.9","tape":"^2.14.0"},"dependencies":{"inherits":"^2.0.1","readable-stream":"~1.0.26-2","zuul":"^1.10.1"},"keywords":["duplexer","streams","streams2","duplex","readable","writable"],"gitHead":"f3cac37aeae9f9da1e36118ad98f211c7357dc0a","homepage":"https://github.com/mcollina/reduplexer","_id":"reduplexer@0.0.7","_shasum":"d4b932205e78c909611e434dec6adecda11e688c","_from":".","_npmVersion":"1.4.21","_npmUser":{"name":"matteo.collina","email":"hello@matteocollina.com"},"maintainers":[{"name":"matteo.collina","email":""}],"dist":{"shasum":"d4b932205e78c909611e434dec6adecda11e688c","size":24523,"noattachment":false,"key":"/reduplexer/-/reduplexer-0.0.7.tgz","tarball":"http://registry.cnpm.dingdandao.com/reduplexer/download/reduplexer-0.0.7.tgz"},"directories":{},"publish_time":1408527451489,"_hasShrinkwrap":false,"_cnpm_publish_time":1408527451489,"_cnpmcore_publish_time":"2021-12-16T16:03:25.918Z"},"0.0.6":{"name":"reduplexer","version":"0.0.6","description":"Another Stream2 duplexer","main":"index.js","scripts":{"test":"tap test.js"},"pre-commit":["test"],"website":"https://github.com/mcollina/reduplexer","repository":{"type":"git","url":"https://github.com/mcollina/reduplexer.git"},"bugs":{"url":"http://github.com/mcollina/reduplexer/issues"},"author":{"name":"Matteo Collina","email":"hello@matteocollina.com"},"license":"ISC","devDependencies":{"tap":"~0.4.8","pre-commit":"0.0.4"},"dependencies":{"readable-stream":"~1.0.26-2"},"homepage":"https://github.com/mcollina/reduplexer","_id":"reduplexer@0.0.6","_shasum":"85f600dd5c9407c8e4cfcbab2309d0743780f492","_from":".","_npmVersion":"1.4.9","_npmUser":{"name":"matteo.collina","email":"hello@matteocollina.com"},"maintainers":[{"name":"matteo.collina","email":""}],"dist":{"shasum":"85f600dd5c9407c8e4cfcbab2309d0743780f492","size":24345,"noattachment":false,"key":"/reduplexer/-/reduplexer-0.0.6.tgz","tarball":"http://registry.cnpm.dingdandao.com/reduplexer/download/reduplexer-0.0.6.tgz"},"directories":{},"publish_time":1406707316042,"_hasShrinkwrap":false,"_cnpm_publish_time":1406707316042,"_cnpmcore_publish_time":"2021-12-16T16:03:26.333Z"},"0.0.5":{"name":"reduplexer","version":"0.0.5","description":"Another Stream2 duplexer","main":"index.js","scripts":{"test":"tap test.js"},"pre-commit":["test"],"website":"https://github.com/mcollina/reduplexer","repository":{"type":"git","url":"https://github.com/mcollina/reduplexer.git"},"bugs":{"url":"http://github.com/mcollina/reduplexer/issues"},"author":{"name":"Matteo Collina","email":"hello@matteocollina.com"},"license":"ISC","devDependencies":{"tap":"~0.4.8","pre-commit":"0.0.4"},"dependencies":{"readable-stream":"~1.0.26-2"},"homepage":"https://github.com/mcollina/reduplexer","_id":"reduplexer@0.0.5","_shasum":"be8877a80a0c77b9d20b5d57d482d1a44bcbda2f","_from":".","_npmVersion":"1.4.9","_npmUser":{"name":"matteo.collina","email":"hello@matteocollina.com"},"maintainers":[{"name":"matteo.collina","email":""}],"dist":{"shasum":"be8877a80a0c77b9d20b5d57d482d1a44bcbda2f","size":24177,"noattachment":false,"key":"/reduplexer/-/reduplexer-0.0.5.tgz","tarball":"http://registry.cnpm.dingdandao.com/reduplexer/download/reduplexer-0.0.5.tgz"},"directories":{},"publish_time":1406546778879,"_hasShrinkwrap":false,"_cnpm_publish_time":1406546778879,"_cnpmcore_publish_time":"2021-12-16T16:03:26.710Z"},"0.0.4":{"name":"reduplexer","version":"0.0.4","description":"Another Stream2 duplexer","main":"index.js","scripts":{"test":"tap test.js"},"pre-commit":["test"],"website":"https://github.com/mcollina/reduplexer","repository":{"type":"git","url":"https://github.com/mcollina/reduplexer.git"},"bugs":{"url":"http://github.com/mcollina/reduplexer/issues"},"author":{"name":"Matteo Collina","email":"hello@matteocollina.com"},"license":"ISC","devDependencies":{"tap":"~0.4.8","pre-commit":"0.0.4"},"dependencies":{"readable-stream":"~1.0.26-2"},"homepage":"https://github.com/mcollina/reduplexer","_id":"reduplexer@0.0.4","_shasum":"1c68bf24a422b87d196a6ea425062b43e6bfd8d1","_from":".","_npmVersion":"1.4.9","_npmUser":{"name":"matteo.collina","email":"hello@matteocollina.com"},"maintainers":[{"name":"matteo.collina","email":""}],"dist":{"shasum":"1c68bf24a422b87d196a6ea425062b43e6bfd8d1","size":18295,"noattachment":false,"key":"/reduplexer/-/reduplexer-0.0.4.tgz","tarball":"http://registry.cnpm.dingdandao.com/reduplexer/download/reduplexer-0.0.4.tgz"},"directories":{},"publish_time":1406541935109,"_hasShrinkwrap":false,"_cnpm_publish_time":1406541935109,"_cnpmcore_publish_time":"2021-12-16T16:03:26.951Z"},"0.0.3":{"name":"reduplexer","version":"0.0.3","description":"Another Stream2 duplexer","main":"index.js","scripts":{"test":"tap test.js"},"pre-commit":["test"],"website":"https://github.com/mcollina/reduplexer","repository":{"type":"git","url":"https://github.com/mcollina/reduplexer.git"},"bugs":{"url":"http://github.com/mcollina/reduplexer/issues"},"author":{"name":"Matteo Collina","email":"hello@matteocollina.com"},"license":"ISC","devDependencies":{"tap":"~0.4.8","pre-commit":"0.0.4"},"dependencies":{"readable-stream":"~1.0.26-2"},"homepage":"https://github.com/mcollina/reduplexer","_id":"reduplexer@0.0.3","_shasum":"6865e42525fed5c045022d62e0d15958f2c3c457","_from":".","_npmVersion":"1.4.9","_npmUser":{"name":"matteo.collina","email":"hello@matteocollina.com"},"maintainers":[{"name":"matteo.collina","email":""}],"dist":{"shasum":"6865e42525fed5c045022d62e0d15958f2c3c457","size":17855,"noattachment":false,"key":"/reduplexer/-/reduplexer-0.0.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/reduplexer/download/reduplexer-0.0.3.tgz"},"directories":{},"publish_time":1406540918013,"_hasShrinkwrap":false,"_cnpm_publish_time":1406540918013,"_cnpmcore_publish_time":"2021-12-16T16:03:27.527Z"},"0.0.2":{"name":"reduplexer","version":"0.0.2","description":"Another Stream2 duplexer","main":"index.js","scripts":{"test":"tap test.js"},"pre-commit":["test"],"website":"https://github.com/mcollina/reduplexer","repository":{"type":"git","url":"https://github.com/mcollina/reduplexer.git"},"bugs":{"url":"http://github.com/mcollina/reduplexer/issues"},"author":{"name":"Matteo Collina","email":"hello@matteocollina.com"},"license":"ISC","devDependencies":{"tap":"~0.4.8","pre-commit":"0.0.4"},"dependencies":{"readable-stream":"~1.0.26-2"},"homepage":"https://github.com/mcollina/reduplexer","_id":"reduplexer@0.0.2","dist":{"shasum":"b8621757df675f932acfd870c7561bd4ba0ff1a6","size":21363,"noattachment":false,"key":"/reduplexer/-/reduplexer-0.0.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/reduplexer/download/reduplexer-0.0.2.tgz"},"_from":".","_npmVersion":"1.3.24","_npmUser":{"name":"matteo.collina","email":"hello@matteocollina.com"},"maintainers":[{"name":"matteo.collina","email":""}],"directories":{},"publish_time":1394707013554,"_hasShrinkwrap":false,"_cnpm_publish_time":1394707013554,"_cnpmcore_publish_time":"2021-12-16T16:03:27.787Z"},"0.0.1":{"name":"reduplexer","version":"0.0.1","description":"Another Stream2 duplexer","main":"index.js","scripts":{"test":"tap test.js"},"pre-commit":["test"],"website":"https://github.com/mcollina/reduplexer","repository":{"type":"git","url":"https://github.com/mcollina/reduplexer.git"},"bugs":{"url":"http://github.com/mcollina/reduplexer/issues"},"author":{"name":"Matteo Collina","email":"hello@matteocollina.com"},"license":"ISC","devDependencies":{"tap":"~0.4.8","pre-commit":"0.0.4"},"dependencies":{"readable-stream":"~1.0.26-2"},"homepage":"https://github.com/mcollina/reduplexer","_id":"reduplexer@0.0.1","dist":{"shasum":"4a8852e29888d27bae25b916778edd877e67eeff","size":19627,"noattachment":false,"key":"/reduplexer/-/reduplexer-0.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/reduplexer/download/reduplexer-0.0.1.tgz"},"_from":".","_npmVersion":"1.3.24","_npmUser":{"name":"matteo.collina","email":"hello@matteocollina.com"},"maintainers":[{"name":"matteo.collina","email":""}],"directories":{},"publish_time":1394699893288,"_hasShrinkwrap":false,"_cnpm_publish_time":1394699893288,"_cnpmcore_publish_time":"2021-12-16T16:03:28.042Z"}},"readme":"# reduplexer(writable, readable, options)\n\n[![build status][1]][2]\n\nTakes a [`Writable`][5] stream and a [`Readable`][4] stream and makes them appear as a `Duplex` stream.\nHeavily inspired by [duplexer](http://npm.im/duplexer) but using Stream2\nwith a bundled [readable-stream](http://npm.im/readable-stream).\n\nIt is assumed that the two streams are connected to each other in some way.\n\n## Example\n\n```js\nvar cp        = require('child_process')\n  , duplexer  = require('reduplexer')\n  , grep      = cp.exec('grep Stream')\n\nduplexer(grep.stdin, grep.stdout, { objectMode: true })\n```\n\n## Installation\n\n`npm install reduplexer --save`\n\n## API\n\n  * <a href=\"#reduplexer\"><code><b>reduplexer()</b></code></a>\n  * <a href=\"#hookWritable\"><code>duplex.<b>hookWritable()</b></code></a>\n  * <a href=\"#hookReadable\"><code>duplex.<b>hookReadable()</b></code></a>\n  * <a href=\"#hook\"><code>duplex.<b>hook()</b></code></a>\n\n-------------------------------------------------------\n<a name=\"reduplexer\"></a>\n### reduplexer(writable, readable, options)\n\nCreate a [`Duplex`][3] stream based on `writable` and `readable` using\nthe given options.\n`writable` and `readable` can be null, and in that case they can be\n'hooked' later.\n\n-------------------------------------------------------\n<a name=\"hookWritable\"></a>\n\n### duplex.hookWritable(writable)\n\nHooks a `Writable` stream. It will throw if a `Writable` is already hooked.\n\n-------------------------------------------------------\n<a name=\"hookReadable\"></a>\n### duplex.hookReadable(writable)\n\nHooks a `Readable` stream. It will throw if a `Readable` stream is already hooked.\n\n-------------------------------------------------------\n<a name=\"hook\"></a>\n### duplex.hook(writable, readable)\n\nShortcut for:\n\n```js\nduplex.hookWritable(writable)\nduplex.hookReadable(readable)\n```\n\nBut it will not throw if any of the two are missing.\n\n## Tests\n\n`npm test`\n\n## License\n\nCopyright (c) 2014, Matteo Collina <hello@matteocollina.com>\n\nPermission to use, copy, modify, and/or distribute this software for any\npurpose with or without fee is hereby granted, provided that the above\ncopyright notice and this permission notice appear in all copies.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES\nWITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF\nMERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR\nANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES\nWHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN\nACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR\nIN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.\n\n  [1]: https://secure.travis-ci.org/mcollina/reduplexer.png\n  [2]: https://travis-ci.org/mcollina/reduplexer\n  [3]: http://nodejs.org/api/stream.html#stream_class_stream_duplex\n  [4]: http://nodejs.org/api/stream.html#stream_class_stream_readable\n  [5]: http://nodejs.org/api/stream.html#stream_class_stream_writable\n","_attachments":{},"homepage":"https://github.com/mcollina/reduplexer","bugs":{"url":"http://github.com/mcollina/reduplexer/issues"},"license":"ISC"}