* @template T * @param Closure(int, T): void $handler * @return T */
(Closure $handler)
| 4048 | * @return T |
| 4049 | */ |
| 4050 | public function process(Closure $handler): mixed |
| 4051 | { |
| 4052 | $params = (new \ReflectionFunction($handler))->getParameters(); |
| 4053 | $type = $params[1]->getType(); |
| 4054 | $class = $type instanceof \ReflectionNamedType ? $type->getName() : 'stdClass'; |
| 4055 | return (new \ReflectionClass($class))->newInstanceWithoutConstructor(); |
| 4056 | } |
| 4057 | } |
| 4058 | |
| 4059 | class ScaffoldingTemplateCallableHolder |
no test coverage detected