code: public function setTransactionClass($transactionClass)
      {
          if (!is_callable($transactionClass) && !class_exists($transactionClass)) {
              throw new \InvalidArgumentException('$transactionClass must be a valid classname or a PHP callable');
          }
  
          $this->transactionClass = $transactionClass;
          return $this;
      }
docs: Set the classname of the transaction class or callable that returns an object that
  implements the StatementInterface.
  
  The callable is not passed any arguments.
  
  $reader->setTransactionClass(function () {
  return new My\Transaction();
  });
  
  @param string|callable $transactionClass
  @return $this