Supports validating all primitive types.
@todo: Move this below the TypedData core component.
@Plugin(
id = "PrimitiveType",
label = @Translation("Primitive type", context = "Validation")
)
Expanded class hierarchy of PrimitiveTypeConstraint
class PrimitiveTypeConstraint extends SymfonyConstraint {
public $message = 'This value should be of type %type.';
}
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
Constraint:: |
public | property | ||
Constraint:: |
public | function | Adds the given group if this constraint is in the Default group | |
Constraint:: |
constant | Marks a constraint that can be put onto classes | ||
Constraint:: |
constant | The name of the group given to all constraints with no explicit group | ||
Constraint:: |
public | function | Returns whether the constraint can be put onto classes, properties or both | 7 |
Constraint:: |
constant | Marks a constraint that can be put onto properties | ||
Constraint:: |
public | function | Returns the name of the class that validates this constraint | 2 |
Constraint:: |
public | function | Initializes the constraint with options. | 10 |
Constraint:: |
public | function | Unsupported operation. | |
PrimitiveTypeConstraint:: |
public | property |
Overrides Type:: |
|
Type:: |
public | property | ||
Type:: |
public | function |
Returns the name of the default option Overrides Constraint:: |
|
Type:: |
public | function |
Returns the name of the required options Overrides Constraint:: |