1: <?php declare(strict_types = 1);
2:
3: namespace PHPStan\Reflection;
4:
5: use PHPStan\Turbo\ReferencedByTurboExtension;
6: use PHPStan\Type\Generic\TemplateTypeVarianceMap;
7: use PHPStan\Type\Type;
8:
9: /**
10: * Extended function/method signature with separate PHPDoc and native types.
11: *
12: * Extends ParametersAcceptor with:
13: * - Extended parameter reflections (separate PHPDoc/native types per parameter)
14: * - Separate PHPDoc and native return types (vs the combined return type from ParametersAcceptor)
15: * - Call-site variance map for template type parameters
16: *
17: * This is the return type of FunctionReflection::getVariants() and
18: * ExtendedMethodReflection::getVariants().
19: *
20: * @api
21: * @api-do-not-implement
22: */
23: #[ReferencedByTurboExtension(key: 'extendedParametersAcceptor')]
24: interface ExtendedParametersAcceptor extends ParametersAcceptor
25: {
26:
27: /** @return list<ExtendedParameterReflection> */
28: public function getParameters(): array;
29:
30: public function getPhpDocReturnType(): Type;
31:
32: public function getNativeReturnType(): Type;
33:
34: public function getCallSiteVarianceMap(): TemplateTypeVarianceMap;
35:
36: }
37: