Total Complexity | 9 |
Total Lines | 63 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 1 |
1 | <?php |
||
18 | class Path extends Dsn |
||
19 | { |
||
20 | use UserPasswordTrait; |
||
21 | /** |
||
22 | * @var string |
||
23 | */ |
||
24 | private $path; |
||
25 | |||
26 | /** |
||
27 | * @param array{ user?: string|null, password?: string|null, } $authentication |
||
|
|||
28 | */ |
||
29 | public function __construct(string $scheme, string $path, array $parameters = [], array $authentication = []) |
||
34 | } |
||
35 | |||
36 | public function getScheme(): string |
||
37 | { |
||
38 | return parent::getScheme(); |
||
39 | } |
||
40 | |||
41 | /** |
||
42 | * @return static |
||
43 | */ |
||
44 | public function withScheme(?string $scheme) |
||
51 | } |
||
52 | |||
53 | public function getPath(): string |
||
54 | { |
||
55 | return $this->path; |
||
56 | } |
||
57 | |||
58 | /** |
||
59 | * @return static |
||
60 | */ |
||
61 | public function withPath(string $path) |
||
62 | { |
||
63 | $new = clone $this; |
||
64 | $new->path = $path; |
||
65 | |||
66 | return $new; |
||
67 | } |
||
68 | |||
69 | /** |
||
70 | * @var string |
||
71 | */ |
||
72 | public function __toString() |
||
81 | } |
||
82 | } |
||
83 |