dart-stream

0.0.0 • Public • Published

DartStream

create a duplex stream kinda like how I imagine they might in dart.

 
var dartStream = require('dart-stream')
 
var ds = dartStream(function readable () {
      //get data like this:
      var data
      while(data = this.readIn()){
        //write data like this:
        this.writeOut(data)
      } 
 
    }, function ended() {
      this.writeEnd()
    })
 

streams are buffered at both the readable and the writable side.

tests

this stream is tested with stream-spec and stream-tester

Readme

Keywords

none

Package Sidebar

Install

npm i dart-stream

Weekly Downloads

1

Version

0.0.0

License

BSD

Last publish

Collaborators

  • nopersonsmodules