You are here

public function ConstraintViolation::getConstraint in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/validator/ConstraintViolation.php \Symfony\Component\Validator\ConstraintViolation::getConstraint()

Returns the constraint whose validation caused the violation.

Return value

Constraint|null The constraint or null if it is not known

File

vendor/symfony/validator/ConstraintViolation.php, line 221

Class

ConstraintViolation
Default implementation of {@ConstraintViolationInterface}.

Namespace

Symfony\Component\Validator

Code

public function getConstraint() {
  return $this->constraint;
}