public static function registerBusQueueingDispatcher(ContainerInterface $container): QueueingDispatcherContract
    {
        return new QueueingDispatcher($container, static function ($connection = null) use ($container) {
            return $container->get(FactoryContract::class)->connection($connection);
        });
    }
public static function registerBusQueueingDispatcher(ContainerInterface $container): QueueingDispatcherContract
    {
        return new QueueingDispatcher($container, static function ($connection = null) use ($container) {
            return $container->get(FactoryContract::class)->connection($connection);
        });
    }
public static function registerBusQueueingDispatcher ( ContainerInterface $ container ) : QueueingDispatcherContract { return new QueueingDispatcher ( $ container , static function ( $ connection = null ) use ( $ container ) { return $ container -> get ( FactoryContract :: class ) -> connection ( $ connection ) ; } ) ; }
Create a new QueueingDispatcher instance.

@param \Psr\Container\ContainerInterface $container

@return \Viserio\Component\Contract\Bus\QueueingDispatcher
Create a new QueueingDispatcher instance .