You are here

public function Dependency::__construct in Drupal 8

Same name and namespace in other branches
  1. 9 core/lib/Drupal/Core/Extension/Dependency.php \Drupal\Core\Extension\Dependency::__construct()
  2. 10 core/lib/Drupal/Core/Extension/Dependency.php \Drupal\Core\Extension\Dependency::__construct()

Dependency constructor.

Parameters

string $name: The name of the dependency.

string $project: The project namespace for the dependency.

string $constraint: The constraint string. For example, '>8.x-1.1'.

File

core/lib/Drupal/Core/Extension/Dependency.php, line 55

Class

Dependency
A value object representing dependency information.

Namespace

Drupal\Core\Extension

Code

public function __construct($name, $project, $constraint) {
  $this->name = $name;
  $this->project = $project;
  $this->constraintString = $constraint;
}