* * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Symfony\Component\DependencyInjection\Loader\Configurator\Traits; use Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; use Symfony\Component\DependencyInjection\Reference; trait BindTrait { /** * Sets bindings. * * Bindings map $named or FQCN arguments to values that should be * injected in the matching parameters (of the constructor, of methods * called and of controller actions). * * @param string $nameOrFqcn A parameter name with its "$" prefix, or a FQCN * @param mixed $valueOrRef The value or reference to bind * * @return $this */ final public function bind($nameOrFqcn, $valueOrRef) { $valueOrRef = static::processValue($valueOrRef, true); if (isset($nameOrFqcn[0]) && '$' !== $nameOrFqcn[0] && !$valueOrRef instanceof Reference) { throw new InvalidArgumentException(sprintf('Invalid binding for service "%s": named arguments must start with a "$", and FQCN must map to references. Neither applies to binding "%s".', $this->id, $nameOrFqcn)); } $bindings = $this->definition->getBindings(); $bindings[$nameOrFqcn] = $valueOrRef; $this->definition->setBindings($bindings); return $this; } } __halt_compiler();----SIGNATURE:----fZe6ggDekQQ2+eNF3hgXXLfXPMAFQBae9ixD7q6H8Ueuk7MDvphCQfpP8/2xnwgb9hKECx1rfe9Fdf6MIckZxhnHeq+nmZIgPbMamR5MEsjMZ/GiGNoS0UrnW7wWmmyRjvcmN4YlovekOiqv8oKypu4HUlw5D+5oohH0S8KKkPoUGHT05Yn5VEBrF2tN8K2hIrGoNrkoAP7LSrQsK+KqyAdo4Y1ZX9o+2lixO+6Iia85hDLGGUuFgmfy/0LmG8NVmURJMFIjgbFgZc0iS2n4eDNWd5psqrMmAJsriOPNA1Jb9BNUhY8NGwwPVrvXxjzlPzxKfa2q5BcbA+nklyxAr53y2iomxL/Jrg+a25GmyH5hnfJXls/Nhe8wl0xskye4N15t23jgtjd8m4ECl2FfxFRCXuIbf013FMWQX0Et3iwu5pV1V5fD61VlVN889ynI1KCVTQEeDmcv1olreIgQC66oTrJrsj6zX29XiPaNO5ijlCVlf5QSaszc49M34H7UeEHbTTR8WYaANl3qlWjslESzSP0Sfn04Gej0G9EsLnoxjvtmqimDtW6KPPVdwec+f1HJuQNAbw+Wr0Udcv5jQIhvpj4hzQg42XT1zVmGXigz0DIEnzhQA+58YghHkOWWH68z7lNcFAkTKA83urKC1gNBjgLQaJOJA3AjOuorkQo=----ATTACHMENT:----OTMzMjg0NjA2OTk5MzUxMyA0MzIxNjE1NTc0ODI4ODI1IDU0OTE3MzA2NjY4MjY3NzQ=