Completed
Push — master ( ca6e2c...137b9b )
by Pol
01:51
created

SubsetItem   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 41
Duplicated Lines 0 %

Coupling/Cohesion

Dependencies 0

Test Coverage

Coverage 81.82%

Importance

Changes 0
Metric Value
wmc 4
cbo 0
dl 0
loc 41
ccs 9
cts 11
cp 0.8182
rs 10
c 0
b 0
f 0

4 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
A getValue() 0 3 1
A getKey() 0 3 1
A getItem() 0 3 1
1
<?php
2
3
namespace drupol\phpartition;
4
5
/**
6
 * Class SubsetItem.
7
 *
8
 * @package drupol\phpartition
9
 */
10
class SubsetItem {
11
12
  protected $key;
13
  protected $value;
14
  protected $item;
15
16
  /**
17
   * SubsetItem constructor.
18
   *
19
   * @param $key
20
   * @param $value
21
   * @param $item
22
   */
23 4
  public function __construct($key, $value, $item) {
24 4
    $this->key = $key;
25 4
    $this->value = $value;
26 4
    $this->item = $item;
27 4
  }
28
29
  /**
30
   * @return mixed
31
   */
32 2
  public function getValue() {
33 2
    return $this->value;
34
  }
35
36
  /**
37
   * @return mixed
38
   */
39
  public function getKey(){
40
    return $this->key;
41
  }
42
43
  /**
44
   * @return mixed
45
   */
46 4
  public function getItem() {
47 4
    return $this->item;
48
  }
49
50
}