{"name":"it-pb-rpc","template":{"extends":["node"]},"version":"0.1.8","description":"A convenience-wrapper around protocol-buffers and lp-messages functions","main":"src/index.js","types":"src/index.d.ts","author":{"name":"Maciej Krüger","email":"mkg20001@gmail.com"},"license":"MPL-2.0","scripts":{"test":"mocha -A","cov":"nyc mocha"},"devDependencies":{"@types/bl":"^2.1.0","it-pair":"^1.0.0","mkgs-tool":"^0.1.6","mocha":"*","nyc":"*","streaming-iterables":"^4.1.2"},"dependencies":{"is-buffer":"^2.0.4","it-handshake":"^1.0.1","it-length-prefixed":"^3.0.1"},"repository":{"type":"git","url":"git+https://github.com/mkg20001/it-pb-rpc.git"},"bugs":{"url":"https://github.com/mkg20001/it-pb-rpc/issues"},"homepage":"https://github.com/mkg20001/it-pb-rpc#readme","gitHead":"eaac1e42bf892f898ddb8eadc15dc75b79bf8b0a","_id":"it-pb-rpc@0.1.8","_nodeVersion":"12.16.1","_npmVersion":"6.13.4","dist":{"integrity":"sha512-YePzUUonithCTIdVKcOeQEn5mpipCg7ZoWsq7jfjXXtAS6gm6R7KzCe6YBV97i6bljU8hGllTG67FiGfweKNKg==","shasum":"eed8ffdcba2a322a20a45c9db9ec5644499ccaf2","tarball":"http://registry-npm.ywwl.com/it-pb-rpc/download/it-pb-rpc-0.1.8.tgz","fileCount":5,"unpackedSize":7808,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeh0dZCRA9TVsSAnZWagAArb8QAJ82SWA/U4F/GJy3YX08\nUt4ab+QajDc0HAI8lvtJaByuJ+1YiGb8c6ZXTRBhVfRg5mmfsQ1zakA73bXp\ngBFMaN8GUwpuyY/Rr2P2UFRDmZsn0haAIIU1ExnhClXJxf4UJWgx5ZwzizBu\nZa3E4dJllQKinVaWOJZRFus5W5j5HPf27ANy3EoqDjNNEPAI9FtP0sHQUfAv\nCEz0xzxeb74o2deyEnED7QXilgAsFOHY70TNoYKMZfKLpV8H0CH+htUyGGLX\nMB/1FKyZ0uBZkHJmbRYSRkCZ/6+V0nXbeLVgBxOBSdsco+PqjEXdjbfu65DC\ndGXLetBK9Wt6m6wVh/x3iDQSZsFc/xcBgQlOkTLcXTnJNE5p6ghqrE9zwnWR\nY2pHrp68Fx/kw0utKwlWVi/d4uXA5rGJvFV6p30Wh5v0fnULHOD8HSVq6doI\nvulEVSGMl/0Jpxj1ZhGTycsVaMQD5qImEm7bezP6IUZrztXVWltu4mWiY+Ko\nO+pQ6q3Mvt+7ZD0vifxfc6hoHREA+Wkw3J78B6ODgnmh121WHkpx82A+OX3J\nTN3NTPbbLkUJhajAZS/MFibJFwQ88yyAF3GFfA/u05IBQ+6fm3DFhEbayu3M\nW0p+2XER6WbGnssWMYHczqMSEpZRqOYvohkjhN7IwkyGNdoSJy/7/0RDLmlT\nMrDe\r\n=Wpwg\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD24ztfoq/TA+6wvGuDbu/Jn1pj1glyFTWNM++UXnu10gIgUQq0MAgw5UX3Oz7ZmwB3zL5aUJ8NstjL/OWdfvnyN2w="}],"size":2469,"noattachment":false,"key":"/it-pb-rpc/-/it-pb-rpc-0.1.8.tgz"},"maintainers":[{"name":"mkg20001","email":"mkg20001@gmail.com"}],"_npmUser":{"name":"mkg20001","email":"mkg20001@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/it-pb-rpc_0.1.8_1585923928591_0.3764166585911317"},"_hasShrinkwrap":false,"readme":"# it-pb-rpc\n\nA convinience-wrapper arround protocol-buffers and lp-messages functions\n\n# API\n\n- `wrap(duplex, opts)`: Wraps a duplex, returns below object (opts=Object with encode/decode opts from [it-length-prefixed api](https://www.npmjs.com/package/it-length-prefixed#api))\n  - `.read(bytes)`: async, reads the given amount of bytes\n  - `.readLP()`: async, reads one length-prefixed message\n  - `.readPB(proto)`: async, reads one protocol-buffers length-prefixed message (proto=Object with .encode, .decode functions)\n  - `.write(data)`: writes the given data (data=Buffer or BufferList)\n  - `.writeLP(data)`: writes the given data with a length-prefixe (data=Buffer or BufferList)\n  - `.writePB(data, proto)`: encodes the data, then writes it withg a length-prefix (data=Buffer or BufferList, proto=Object with .encode, .decode functions)\n  - `.pb(proto)`: returns a convinience wrapper for writing messages\n    - `.read()`: reads one length-prefixed message encoded with `proto`\n    - `.write(data)`: writes one length-prefixed message encoded with `proto`\n","publish_time":1585923928774,"_cnpm_publish_time":1585923928774,"dist-tags":{"latest":"0.2.0"}}