streamify-your-node-program
streamify-your-node-program copied to clipboard
在node.9.5.0中已经不叫next了
在node.9.5.0的中doWrite()的部分源码如下
if (writev)//_writev是批量写入数据,如果有就优先调用之
stream._writev(chunk, state.onwrite);
else//否则调用默认的版本
stream._write(chunk, encoding, state.onwrite);
state.sync = false;
_write和_writev的回调已经不叫next了,建议文章也同步修改一下