-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCannotAutowireDependencyArgument.php
More file actions
47 lines (39 loc) · 1.01 KB
/
CannotAutowireDependencyArgument.php
File metadata and controls
47 lines (39 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
<?php
namespace Technically\DependencyResolver\Exceptions;
use Throwable;
final class CannotAutowireDependencyArgument extends DependencyResolutionException
{
/**
* @var string
*/
private string $dependencyName;
/**
* @var string
*/
private string $argumentName;
/**
* @param string $dependencyName
* @param string $argumentName
* @param Throwable|null $previous
*/
public function __construct(string $dependencyName, string $argumentName, Throwable $previous = null)
{
$this->dependencyName = $dependencyName;
$this->argumentName = $argumentName;
parent::__construct("Could not autowire argument `{$argumentName}` for `${dependencyName}`.", 0, $previous);
}
/**
* @return string
*/
public function getDependencyName(): string
{
return $this->dependencyName;
}
/**
* @return string
*/
public function getArgumentName(): string
{
return $this->argumentName;
}
}