Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Dependency.php

function Dependency::getConstraint

Gets the Constraint object.

Return value

\Drupal\Component\Version\Constraint The Constraint object.

File

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

Class

Dependency
A value object representing dependency information.

Namespace

Drupal\Core\Extension

Code

protected function getConstraint() {
    if (!$this->constraint) {
        $this->constraint = new Constraint($this->constraintString, \Drupal::CORE_COMPATIBILITY);
    }
    return $this->constraint;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal