File tree 2 files changed +27
-0
lines changed
stubs/Symfony/Component/Form
2 files changed +27
-0
lines changed Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ parameters:
15
15
- stubs/Symfony/Component/EventDispatcher/EventDispatcherInterface.stub
16
16
- stubs/Symfony/Component/EventDispatcher/EventSubscriberInterface.stub
17
17
- stubs/Symfony/Component/EventDispatcher/GenericEvent.stub
18
+ - stubs/Symfony/Component/Form/DataTransformerInterface.stub
18
19
- stubs/Symfony/Component/Form/FormBuilderInterface.stub
19
20
- stubs/Symfony/Component/Form/FormInterface.stub
20
21
- stubs/Symfony/Component/Form/FormTypeExtensionInterface.stub
Original file line number Diff line number Diff line change
1
+ <?php
2
+
3
+ namespace Symfony\Component\Form;
4
+
5
+ use Symfony\Component\Form\Exception\TransformationFailedException;
6
+
7
+ /**
8
+ * @phpstan-template T
9
+ * @phpstan-template R
10
+ */
11
+ interface DataTransformerInterface
12
+ {
13
+ /**
14
+ * @phpstan-param T|null $value The value in the original representation
15
+ *
16
+ * @phpstan-return R|null The value in the transformed representation
17
+ */
18
+ public function transform($value);
19
+
20
+ /**
21
+ * @phpstan-param R|null $value The value in the transformed representation
22
+ *
23
+ * @phpstan-return T|null The value in the original representation
24
+ */
25
+ public function reverseTransform($value);
26
+ }
You can’t perform that action at this time.
0 commit comments