Interface Yiisoft\Hydrator\TypeCaster\TypeCasterInterface
Casts value to a type obtained from {@see ReflectionType} passed.
Public Methods
| Method | Description | Defined By |
|---|---|---|
| cast() | Yiisoft\Hydrator\TypeCaster\TypeCasterInterface |
Method Details
| public abstract Yiisoft\Hydrator\Result cast ( mixed $value, Yiisoft\Hydrator\TypeCaster\TypeCastContext $context ) | ||
| $value | mixed |
Value to cast. |
| $context | Yiisoft\Hydrator\TypeCaster\TypeCastContext |
Type cast context. |
| return | Yiisoft\Hydrator\Result |
The result object. |
|---|---|---|
public function cast(mixed $value, TypeCastContext $context): Result;
Signup or Login in order to comment.