PropertyDefinition::getVariable()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 3
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 0
crap 1
1
<?php
2
3
  namespace Funivan\Cs\Tools\Php\RedundantNullPropertyValue;
4
5
  use Funivan\PhpTokenizer\Token;
6
7
  /**
8
   *
9
   */
10
  class PropertyDefinition {
11
12
    /**
13
     * @var Token
14
     */
15
    private $variable;
16
17
    /**
18
     * @var array
19
     */
20
    private $tokensToReplace;
21
22
23
    /**
24
     * @param Token $variable
25
     * @param array $tokensToReplace
26
     */
27 10
    public function __construct(Token $variable, array $tokensToReplace) {
28 10
      $this->variable = $variable;
29 10
      $this->tokensToReplace = $tokensToReplace;
30 10
    }
31
32
33
    /**
34
     * @return Token
35
     */
36 10
    public function getVariable() {
37 10
      return $this->variable;
38
    }
39
40
41
    /**
42
     * @return Token[]
43
     */
44 8
    public function getTokensToReplace() {
45 8
      return $this->tokensToReplace;
46
    }
47
48
49
  }