*/ class DecoratorResolver implements DefinitionResolver { /** @var ContainerInterface */ private $container; /** @var DefinitionResolver */ private $definitionResolver; /** * The resolver needs a container. This container will be passed to the factory as a parameter * so that the factory can access other entries of the container. * * @param DefinitionResolver $definitionResolver Used to resolve nested definitions. */ public function __construct(ContainerInterface $container, DefinitionResolver $definitionResolver) { $this->container = $container; $this->definitionResolver = $definitionResolver; } /** * Resolve a decorator definition to a value. * * This will call the callable of the definition and pass it the decorated entry. * * @param DecoratorDefinition $definition */ public function resolve(Definition $definition, array $parameters = []) { $callable = $definition->getCallable(); if (! is_callable($callable)) { throw new InvalidDefinition(sprintf( 'The decorator "%s" is not callable', $definition->getName() )); } $decoratedDefinition = $definition->getDecoratedDefinition(); if (! $decoratedDefinition instanceof Definition) { if (! $definition->getName()) { throw new InvalidDefinition('Decorators cannot be nested in another definition'); } throw new InvalidDefinition(sprintf( 'Entry "%s" decorates nothing: no previous definition with the same name was found', $definition->getName() )); } $decorated = $this->definitionResolver->resolve($decoratedDefinition, $parameters); return call_user_func($callable, $decorated, $this->container); } public function isResolvable(Definition $definition, array $parameters = []): bool { return true; } } __halt_compiler();----SIGNATURE:----Ffs4GJCcpmvoBpdUvz1v9CwTgcfG7LAIwfozIZ6+noVTkpbt2wOLxZ/wBXR87fw01f4Ju84BR8vN71yg/8ibYUvxXxhydDo1snxMmiofJM6Jz3Lnv7V6a7sqh76Su2qULXlmQ/oOSvp8F0lOdcIK9mebClVlNpDVbH/tVWA/21uy0mDRfCh7nfkhP55w8LeUxV0Q6Wh8wPfgUJFWz0dHUxw7ouVOu26gQP04JUe1o8eksFXGa1Q0kYg+zRlDENxpaaXRfGpwhDG0hiEkYACiYafxNqbbvSfyG48U/ulKoVzq9/gIQXAu0tWV8Bs1Ob5WvIib9bar3jhq1SgValaBY299RbfcwCXuGGGYo9LdwF13bPUXf2xIB/2n34Oi7PaB/ItdA1Us21qwPtZMwAobXDm0Lql4XtVvOE7CfgxiMyTT48FMfs3Fo4/Pg/0x+OJjJwggCUUD1pY7TBUamkLkmNktR5PEfumSPrqk9kxe5C4QnLaWMDLD8V0ZPXwjBvL2dLGHRcTpw1YODR5UAECnheEJbuRKtwAycuwMDnYg/qHcglXlIrexue2lK2wI3oFbZtxtpczxn/PyWo+kh+zzMtB0VEVTipw/imLuRfTLq40x22LD+kbEbJ93wHZIVW+I2zQAPmEjYIexropVTDKNgTfwJ6RASt3qiGKDdYJ5WSQ=----ATTACHMENT:----MjExMDY4MTM3MjU2MDk1NiA1MDYwMjQxODc0Mjk2NDM0IDI1MTY3MzU2MDk4NzI0NTc=