@param Driver $driver

@return View

@throws RuntimeException
15403
public function getView(Driver $driver)
    {
        $this->dataExporter->setModelClass($this->modelClass);
        $this->view->setParam('menu', $this->container->getParameter('symfonyid.admin.menu.menu_name'));
        $this->view->setParam('action_method', $this->translator->trans('page.list', array(), $this->container->getParameter('symfonyid.admin.translation_domain')));
        $this->view->setParam('allow_create', $this->allowCreate);
        $this->view->setParam('allow_delete', $this->allowBulkDelete);
        $this->view->setParam('allow_download', $this->dataExporter->isAllowExport($driver, $this->container->getParameter('symfonyid.admin.max_records')));
        $this->view->setParam('number', $this->container->getParameter('symfonyid.admin.number'));
        $this->view->setParam('formating_number', $this->formatNumber);

        $this->setHeader();
        $this->setRecords($driver);

        return $this->view;
    }
862002
public function resolve($driver)
    {
        if ($driver instanceof Grid\Exporters\AbstractExporter) {
            return $driver->setGrid($this->grid);
        }

        return $this->getExporter($driver);
    }
889082
public function toPhinxSqliteMemory(Driver $driver, $database)
    {
        $is_memory = $driver instanceof \Samurai\Onikiri\Driver\SqliteDriver && $database === ':memory:';
        return $is_memory ? true : null;
    }
1206434
public function driver($driver = '')
    {
        if (isset($this->drivers[$driver]) || isset($this->extends[$driver])) {
            $driver = $this->buildDriver($driver);

            return $this->initalizeDriver($driver);
        } else {
            throw new DriverNotFoundException(sprintf('%s driver is not found', $driver));
        }
    }
177315
protected function getFactory($driver) {
        $class = is_object($driver) ? get_class($driver) : $driver;
        foreach ($this->logger as $value) {
            if ($value instanceof $class) {
                return $value;
            }
        }
    }
250458
public function driver($driver)
    {
        if (!isset($this->drivers[$driver])) {
            $this->drivers[$driver] = $this->createDriver($driver);
        }

        return $this->drivers[$driver];
    }
1342021
public function driver($driver)
    {
        $this->container['sms.sender'] = $this->container->share(function ($app) use ($driver) {
            return (new DriverManager($app))->driver($driver);
        });

        $this->driver = $this->container['sms.sender'];
    }
93541
public static function getInstance($driverName = null): AbstractMySQL
    {
        if (!static::$initialized) {
            static::$baseClass = Base::getInstance();
        }
        $driverName = $driverName!==null
            ? '\\MS\\LightFramework\\Db\\MySQL\\Drivers\\'.$driverName
            : '\\MS\\LightFramework\\Db\\MySQL\\Drivers\\'.((string) static::$baseClass->Database->MySQL->driverClass);
        /** @noinspection PhpUndefinedMethodInspection */
        $driver = $driverName::getInstance();

        // @codeCoverageIgnoreStart
        if (!($driver instanceof AbstractMySQL)) {
            throw new RuntimeException('MySQL driver must extend \\MS\\LightFramework\\Db\\MySQL\\AbstractMySQL');
        }
        // @codeCoverageIgnoreEnd

        return $driver;
    }
511366
public function driver( $driver = null )
	{
		$driver = strtolower( $driver ?: $this->getDefaultDriver() );

		// If the given driver has not been created before, we will create the instances
		// here and cache it so we can return it next time very quickly. If there is
		// already a driver created by this name, we'll just return that instance.
		if ( !array_key_exists( $driver, $this->drivers ) )
			$this->drivers[$driver] = $this->createDriver( $driver );

		return $this->drivers[$driver];
	}
537689
public function createView($object)
    {
        $view = $this->viewFactory->createView($object);

        if ($view instanceof View) {
            $this->extend($view, $object);
        }

        return $view;
    }
831190
public function getCache($driver, array $options = array())
    {
        if (!$this->driverExists($driver)) {
            throw new CacheException('The cache driver "'.$driver.'" is not supported by the bundle.');
        }

        $class = $this->drivers[$driver];

        if (!$class::isSupported()) {
            throw new CacheException('The cache driver "'.$driver.'" is not supported by your running configuration.');
        }

        $options = array_merge($this->options, $options);

        $cache = new $class($options);

        if (!$cache instanceof CacheInterface) {
            throw new CacheException('The cache driver "'.$driver.'" must implement CacheInterface.');
        }

        return $cache;
    }
1033075
protected function createDoctrineMappingDriver(ContainerBuilder $container, $driverId, $driverClass)
    {
        $driverDefinition = new Definition($driverClass, array(
            array(realpath(__DIR__.'/../Resources/config/model') => 'Lexik\Bundle\TranslationBundle\Model'),
        ));
        $driverDefinition->setPublic(false);

        $container->setDefinition($driverId, $driverDefinition);
    }
988078
protected function resolveDriver($name)
    {
        if ( ! isset($this->drivers[$name]) || ! $this->container->has($this->drivers[$name])) {
            throw new \RuntimeException(sprintf(
                'Caching driver "%s" does not exist or is not registered as a service.',
                $name
            ));
        }

        $driver = $this->container->get($this->drivers[$name]);

        if ( ! $driver instanceof DriverInterface) {
            throw new \RuntimeException(sprintf(
                'Service "%s" is not a valid caching driver.',
                $this->drivers[$name]
            ));
        }

        return $driver;
    }
788092
public function getView(Driver $driver)
    {
        $output = array(
            'count' => 0,
            'data' => array(),
        );

        if ($this->request->isMethod('POST')) {
            $output = $this->doBulkCreate($driver);
        }

        if (0 === count($output['data'])) {
            $message = 'message.insert_bulk_failed';
        } else {
            $message = 'message.insert_bulk';
        }

        $this->view->setParam('status', empty($output['data']) ? false : true);
        $this->view->setParam('message', $this->translator->trans($message, array(
            '%count%' => count($output['data']),
            '%deleted%' => $output['count'],
            '%data%' => implode(', ', $output['data']),
        ), $this->translationDomain));

        return $this->view;
    }
404064
public function driver($driver = null)
    {
        $driver = $driver ?: $this->getDefaultDriver();

        if (is_null($driver)) {
            throw new InvalidArgumentException(sprintf('Unable to resolve NULL driver for [%s].', get_called_class()));
        }

        // If the given driver has not been created before, we will create the instances
        // here and cache it so we can return it next time very quickly. If there is
        // already a driver created by this name, we'll just return that instance.
        if (! isset($this->drivers[$driver])) {
            $this->drivers[$driver] = $this->createDriver($driver);
        }

        return $this->drivers[$driver];
    }
670513
public static function getInstance($db)
    {
        if (!isset(self::$instances[$db])) {
            $config = config('database.' . $db);
            if (!$config) {
                throw new RuntimeException('Not found database config [' . $db . '], Please checking file config/database.php');
            }

            switch ($config['driver']) {
                case 'mysql':
                    self::$instances[$db] = new MysqlConnection($config);
                    break;
            }
        }

        return self::$instances[$db];
    }
666376
public function driver(string $driver): DriverInterface
    {
        if (isset($this->drivers[$driver])) {
            return $this->drivers[$driver];
        }
        try {
            return $this->drivers[$driver] = $this->config->getDriver($driver)->resolve($this->factory);
        } catch (ContainerExceptionInterface $e) {
            throw new DBALException($e->getMessage(), $e->getCode(), $e);
        }
    }