Retrieve an {@link zpt\db\adapter\SqlAdminAdapter} for the current
connection. This will only be useful if the user associated with the
connection has sufficient priviledges to perform administrative SQL
statements.

@return zpt\db\adapter\SqlAdminAdapter
339444
public function getAdminAdapter() {
		if ($this->adminAdapter === null) {
			$this->adminAdapter = $this->adapterFactory->createAdminAdapter($this);
		}
		return $this->adminAdapter;
	}
718239
public function getAdapter()
    {
        $adapter = $this->dsn->adapter;

        if ($adapter !== null) {
            return $adapter;
        }

        $scheme = $this->dsn->scheme;

        if (isset(static::$adapterMap[$scheme])) {
            return static::$adapterMap[$scheme];
        }

        return null;
    }
146013
public function getDriver()
    {
        $adapter = $this->getAdapter();

        if ($adapter) {
            return $adapter;
        }

        $engine = $this->dsn->engine;

        return 'Cake\Database\Driver\\' . ucfirst($engine);
    }
95593
private function getAclAdapter() {
        $config = $this->getConfig();

        // Access control adapter
        $accessControl = $config['accessControl'];

        if (is_callable($accessControl) && !($accessControl instanceof AdapterInterface)) {
            $accessControl = $accessControl();
        }

        if (!$accessControl instanceof AdapterInterface) {
            throw new RuntimeException('Invalid access control adapter');
        }

        if (!$accessControl instanceof MutableAdapterInterface) {
            throw new RuntimeException('The configured access control adapter is not mutable');
        }

        return $accessControl;
    }
392077
public function getConnector() {
        if (!$this->connector) {
            $mapping = $this->dao->getMapping();
            $this->connector = ConnectionPool::getConnector($mapping['connection']);
        }
        return $this->connector;
    }
533729
public function getAdapter()
    {
        if(!$this->_adapter instanceof KDatabaseAdapterInterface)
        {
            $this->_adapter = $this->getObject($this->_adapter);

            if(!$this->_adapter instanceof KDatabaseAdapterInterface)
            {
                throw new UnexpectedValueException(
                    'Adapter: '.get_class($this->_adapter).' does not implement KDatabaseAdapterInterface'
                );
            }
        }

        return $this->_adapter;
    }
1373253
public function getDatasource()
    {
        $adapter = $this->getAdapter();

        if ($adapter) {
            return $adapter;
        }

        $engine = $this->dsn->engine;

        return 'Database/' . ucfirst($engine);
    }
704524
protected function getAdapter() {
        // Backwards compatability as I won't bump the version number for this
        // yet. When I add PHP 7 support I'll bump it and remove this.
        if (!$this->adapter) {
            $this->adapter = new Curl();
            $this->adapter->setLogger(new NullLogger());
        }
        return $this->adapter;
    }
509786
public function getConnection()
	{
		if ($this->connection === null)
		{
			$connection = null;

			// We will now provide the query grammar to the connection.
			switch ($this->driverName)
			{
				case 'mysql':
					$connection = '\Illuminate\Database\MySqlConnection';
					break;

				case 'pgsql':
					$connection = '\Illuminate\Database\PostgresConnection';
					break;

				case 'sqlsrv':
					$connection = '\Illuminate\Database\SqlServerConnection';
					break;

				case 'sqlite':
					$connection = '\Illuminate\Database\SQLiteConnection';
					break;

				default:
					throw new \InvalidArgumentException("Cannot determine grammar to use based on {$this->driverName}.");
					break;
			}
			
			$this->connection = new $connection($this->pdo, '', $this->tablePrefix);
		}

		return $this->connection;
	}
1243767
public function getEntityManager()
    {

        // check if we have a valid datasource node
        if ($this->getDatasourceNode() == null) {
            return;
        }

        // prepare the path to the entities
        $absolutePaths = array();
        if ($relativePaths = $this->getStepNode()->getParam(AbstractDatabaseStep::PARAM_PATH_TO_ENTITIES)) {
            foreach (explode(PATH_SEPARATOR, $relativePaths) as $relativePath) {
                $absolutePaths[] = $this->getWebappPath() . DIRECTORY_SEPARATOR . $relativePath;
            }
        }

        // load the database connection parameters
        $connectionParameters = $this->getConnectionParameters();

        // initialize and load the entity manager and the schema tool
        $metadataConfiguration = Setup::createAnnotationMetadataConfiguration($absolutePaths, true, null, null, false);
        return EntityManager::create($connectionParameters, $metadataConfiguration);
    }
1257807
public function sql_pconnect()
    {
        $link = parent::sql_pconnect();

        $this->initializeMediator();
        $this->mediator->negotiate();

        return $link;
    }
1217671
protected function getColumnFilterAdapter()
    {
        if (is_null($this->columnFilterAdapter)) {
            $this->columnFilterAdapter = app(ColumnFilterAdapter::class, [$this->collection, get_class($this->datatable)]);
        }
        return $this->columnFilterAdapter;
    }
973126
public function getAdapter()
    {
        /**
         * Check for an adapter being defined. if not, fetch the default adapter.
         */
        if ($this->_adapter === null) {
            $this->_adapter = Zend_Db_Table_Abstract::getDefaultAdapter();
            if (null === $this->_adapter) {

                throw new Zend_Validate_Exception('No database adapter present');
            }
        }
        return $this->_adapter;
    }
782813
public function getExporter()
	{
		// Derive the class name from the driver.
		$class = '\\Joomla\\Database\\' . ucfirst($this->name) . '\\' . ucfirst($this->name) . 'Exporter';

		// Make sure we have an exporter class for this driver.
		if (!class_exists($class))
		{
			// If it doesn't exist we are at an impasse so throw an exception.
			throw new Exception\UnsupportedAdapterException('Database Exporter not found.');
		}

		/** @var $o DatabaseExporter */
		$o = new $class;
		$o->setDbo($this);

		return $o;
	}
128221
public static function getRequestAdapter()
    {
        if (!self::$_requestAdapter) {
            if (class_exists('Zend_Controller_Front', false)) {
                self::$_requestAdapter = new CheddarGetter_Http_ZendAdapter();
            } else {
                self::$_requestAdapter = new CheddarGetter_Http_NativeAdapter();
            }
        }

        return self::$_requestAdapter;
    }
1136104
public function getIdentifier()
    {
        $this->preGetIdentifier();
        $result = $this->dataStore->getIdentifier();

        return $this->postGetIdentifier($result);
    }
600842
public function getAdapter()
    {
        if (isset($this->adapter)) {
            return $this->adapter;
        }
        
        $options = $this->getOptions();
        if (isset($options['connection'])) {
            if (!($options['connection'] instanceof \PDO)) {
                throw new \RuntimeException('The specified connection is not a PDO instance');
            }

            $options['connection']->setAttribute(\PDO::ATTR_ERRMODE, \PDO::ERRMODE_EXCEPTION);
            $options['adapter'] = $options['connection']->getAttribute(\PDO::ATTR_DRIVER_NAME);
        }
        if (!isset($options['adapter'])) {
            throw new \RuntimeException('No adapter was specified for environment: ' . $this->getName());
        }

        $factory = AdapterFactory::instance();
        $adapter = $factory
            ->getAdapter($options['adapter'], $options);

        // Automatically time the executed commands
        $adapter = $factory->getWrapper('timed', $adapter);

        if (isset($options['wrapper'])) {
            $adapter = $factory
                ->getWrapper($options['wrapper'], $adapter);
        }

        if ($this->getInput()) {
            $adapter->setInput($this->getInput());
        }

        if ($this->getOutput()) {
            $adapter->setOutput($this->getOutput());
        }

        // Use the TablePrefixAdapter if table prefix/suffixes are in use
        if ($adapter->hasOption('table_prefix') || $adapter->hasOption('table_suffix')) {
            $adapter = AdapterFactory::instance()
                ->getWrapper('prefix', $adapter);
        }

        $this->setAdapter($adapter);

        return $adapter;
    }