final public static function Database::removeConnection

Remove a connection and its corresponding connection information.

Parameters

$key: The connection key.

Return value

TRUE in case of success, FALSE otherwise.

4 calls to Database::removeConnection()

File

drupal/core/lib/Drupal/Core/Database/Database.php, line 339
Definition of Drupal\Core\Database\Database

Class

Database
Primary front-controller for the database system.

Namespace

Drupal\Core\Database

Code

public static final function removeConnection($key) {
  if (isset(self::$databaseInfo[$key])) {
    self::closeConnection(NULL, $key);
    unset(self::$databaseInfo[$key]);
    return TRUE;
  }
  else {
    return FALSE;
  }
}