public function __construct(FactoryInterface $factory = null, TransportInterface $transport, array $options = null)
{
$this->factory = null === $factory ? new Factory() : $factory;
$this->transport = $transport;
$this->options = array_merge($this->options, (array) $options);
$this->options['transactions'] = $this->options['transactions'] && $transport instanceof TransactionInterface;
// register a stream wrapper to lazily load binary property values
if (null === self::$binaryStreamWrapperRegistered) {
self::$binaryStreamWrapperRegistered = $this->options['stream_wrapper'];
if (self::$binaryStreamWrapperRegistered) {
stream_wrapper_register('jackalope', 'Jackalope\\BinaryStreamWrapper');
}
}
}