public function GenericMetadata::__clone in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/symfony/validator/Mapping/GenericMetadata.php \Symfony\Component\Validator\Mapping\GenericMetadata::__clone()
Clones this object.
File
- vendor/
symfony/ validator/ Mapping/ GenericMetadata.php, line 98
Class
- GenericMetadata
- A generic container of {@link Constraint} objects.
Namespace
Symfony\Component\Validator\MappingCode
public function __clone() {
$constraints = $this->constraints;
$this->constraints = array();
$this->constraintsByGroup = array();
foreach ($constraints as $constraint) {
$this
->addConstraint(clone $constraint);
}
}