public function Constraint::getTargets in Plug 7
Returns whether the constraint can be put onto classes, properties or both.
This method should return one or more of the constants Constraint::CLASS_CONSTRAINT and Constraint::PROPERTY_CONSTRAINT.
@api
Return value
string|array One or more constant values
11 methods override Constraint::getTargets()
- Callback::getTargets in lib/
Symfony/ validator/ Symfony/ Component/ Validator/ Constraints/ Callback.php - Returns whether the constraint can be put onto classes, properties or both.
- ClassConstraint::getTargets in lib/
Symfony/ validator/ Symfony/ Component/ Validator/ Tests/ Fixtures/ ClassConstraint.php - Returns whether the constraint can be put onto classes, properties or both.
- ConstraintA::getTargets in lib/
Symfony/ validator/ Symfony/ Component/ Validator/ Tests/ Fixtures/ ConstraintA.php - Returns whether the constraint can be put onto classes, properties or both.
- ConstraintB::getTargets in lib/
Symfony/ validator/ Symfony/ Component/ Validator/ Tests/ Fixtures/ ConstraintB.php - Returns whether the constraint can be put onto classes, properties or both.
- ConstraintC::getTargets in lib/
Symfony/ validator/ Symfony/ Component/ Validator/ Tests/ Fixtures/ ConstraintC.php - Returns whether the constraint can be put onto classes, properties or both.
File
- lib/
Symfony/ validator/ Symfony/ Component/ Validator/ Constraint.php, line 298
Class
- Constraint
- Contains the properties of a constraint definition.
Namespace
Symfony\Component\ValidatorCode
public function getTargets() {
return self::PROPERTY_CONSTRAINT;
}