Alias   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 35
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 1
Metric Value
wmc 3
c 1
b 0
f 1
lcom 0
cbo 0
dl 0
loc 35
ccs 8
cts 8
cp 1
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
A getAlias() 0 4 1
A getAliased() 0 4 1
1
<?php
2
3
/*
4
 * This file is part of the LaravelYaml package.
5
 *
6
 * (c) Théo FIDRY <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace Fidry\LaravelYaml\DependencyInjection\Definition;
13
14
/**
15
 * This definition is a simple object encapsulating the required data to register an alias to the Application container.
16
 *
17
 * @author Théo FIDRY <[email protected]>
18
 */
19
final class Alias
20
{
21
    /**
22
     * @var string
23
     */
24
    private $alias;
25
26
    /**
27
     * @var string
28
     */
29
    private $aliased;
30
31
    /**
32
     * @param string $alias  Alias name
33
     * @param string $aliased Name of the service for which the alias is for
34
     */
35 2
    public function __construct($alias, $aliased)
36
    {
37 2
        $this->alias = $alias;
38 2
        $this->aliased = $aliased;
39 2
    }
40
41
    /**
42
     * @return string
43
     */
44 2
    public function getAlias()
45
    {
46 2
        return $this->alias;
47
    }
48
49 2
    public function getAliased()
50
    {
51 2
        return $this->aliased;
52
    }
53
}
54