function BufferedWriter(wrappedStream) {
  StringWriter.call(this);
  this._wrapped = wrappedStream;
  this._scheduled = null;
}
Simple wrapper that can be used to wrap a stream
to reduce the number of write calls. In Node.js world,
each stream.write() becomes a chunk. We can avoid overhead
by reducing the number of chunks by buffering the output.