code: public void scan(Scan scan, final ScanResultConsumer consumer) {
      if (AbstractBigtableTable.hasWhileMatchFilter(scan.getFilter())) {
        throw new UnsupportedOperationException(
            "scan with consumer and while match filter is not allowed");
      }
      Query query = hbaseAdapter.adapt(scan);
      clientWrapper.readFlatRowsAsync(query, new StreamObserver<FlatRow>() {
        @Override
        public void onNext(FlatRow value) {
          consumer.onNext(Adapters.FLAT_ROW_ADAPTER.adaptResponse(value));
        }
  
        @Override
        public void onError(Throwable t) {
          consumer.onError(t);
        }
  
        @Override
        public void onCompleted() {
          consumer.onComplete();
        }
      });
    }
docs: {@inheritDoc}