X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs-website;a=blobdiff_plain;f=vendor%2Fbehat%2Fbehat%2Fsrc%2FBehat%2FBehat%2FHelperContainer%2FArgument%2FAutowiringResolver.php;fp=vendor%2Fbehat%2Fbehat%2Fsrc%2FBehat%2FBehat%2FHelperContainer%2FArgument%2FAutowiringResolver.php;h=0000000000000000000000000000000000000000;hp=11dde13b97df883c578aadc960fb4498ff7aef86;hb=af6d1fb995500ae68849458ee10d66abbdcfb252;hpb=680c79a86e3ed402f263faeac92e89fb6d9edcc0 diff --git a/vendor/behat/behat/src/Behat/Behat/HelperContainer/Argument/AutowiringResolver.php b/vendor/behat/behat/src/Behat/Behat/HelperContainer/Argument/AutowiringResolver.php deleted file mode 100644 index 11dde13b9..000000000 --- a/vendor/behat/behat/src/Behat/Behat/HelperContainer/Argument/AutowiringResolver.php +++ /dev/null @@ -1,53 +0,0 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Behat\Behat\HelperContainer\Argument; - -use Behat\Behat\Context\Argument\ArgumentResolver; -use Behat\Behat\HelperContainer\ArgumentAutowirer; -use Psr\Container\ContainerInterface; -use ReflectionClass; - -/** - * Resolves arguments that weren't resolved before by autowiring. - * - * @see ContextFactory - * - * @author Konstantin Kudryashov - */ -final class AutowiringResolver implements ArgumentResolver -{ - /** - * @var ArgumentAutowirer - */ - private $autowirer; - - /** - * Initialises resolver. - * - * @param ContainerInterface $container - */ - public function __construct(ContainerInterface $container) - { - $this->autowirer = new ArgumentAutowirer($container); - } - - /** - * {@inheritdoc} - */ - public function resolveArguments(ReflectionClass $classReflection, array $arguments) - { - if ($constructor = $classReflection->getConstructor()) { - return $this->autowirer->autowireArguments($constructor, $arguments); - } - - return $arguments; - } -}