"Fossies" - the Fresh Open Source Software Archive

Member "Atom/resources/app/apm/node_modules/block-stream/README.md" (17 Oct 2016, 369 Bytes) of archive /windows/misc/atom-windows.zip:

As a special service "Fossies" has tried to format the requested source page into HTML format (assuming markdown format). Alternatively you can here view or download the uninterpreted source code file. A member file download can also be achieved by clicking within a package contents listing on the according byte size field.


A stream of blocks.

Write data into it, and it’ll output data in buffer blocks the size you specify, padding with zeroes if necessary.

javascript var block = new BlockStream(512) fs.createReadStream("some-file").pipe(block) block.pipe(fs.createWriteStream("block-file"))

When .end() or .flush() is called, it’ll pad the block with zeroes.