scripts/filtered-stream-iterator.js
function (streamIterator, onItem) {
  StreamIterator.apply(this, arguments);

  this._streamIterator = streamIterator;
  this._onItem = onItem;

  // Pipe data so that we can filter it in FilteredStreamIterator
  streamIterator.pipe(this);
}
function (streamIterator, onItem) {
  StreamIterator.apply(this, arguments);

  this._streamIterator = streamIterator;
  this._onItem = onItem;

  // Pipe data so that we can filter it in FilteredStreamIterator
  streamIterator.pipe(this);
}
function ( streamIterator , onItem ) { StreamIterator . apply ( this , arguments ) ; this . _streamIterator = streamIterator ; this . _onItem = onItem ; // Pipe data so that we can filter it in FilteredStreamIterator streamIterator . pipe ( this ) ; }
onItem can be a promise factory or just a factory. It should return null when the item should be filtered out.
onItem can be a promise factory or just a factory . It should return null when the item should be filtered out .