You are here

public function DatabaseTestController::__construct in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/system/tests/modules/database_test/src/Controller/DatabaseTestController.php \Drupal\database_test\Controller\DatabaseTestController::__construct()
  2. 9 core/modules/system/tests/modules/database_test/src/Controller/DatabaseTestController.php \Drupal\database_test\Controller\DatabaseTestController::__construct()

Constructs a DatabaseTestController object.

Parameters

\Drupal\Core\Database\Connection $connection: A database connection.

File

core/modules/system/tests/modules/database_test/src/Controller/DatabaseTestController.php, line 30

Class

DatabaseTestController
Controller routines for database_test routes.

Namespace

Drupal\database_test\Controller

Code

public function __construct(Connection $connection) {
  $this->connection = $connection;
}