Total Complexity | 2 |
Total Lines | 27 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 1 | ||
Bugs | 0 | Features | 1 |
1 | <?php |
||
13 | class DefaultWeightedEdge extends DefaultEdge |
||
14 | { |
||
15 | /** |
||
16 | * Weight of the edge |
||
17 | * |
||
18 | * @var float |
||
19 | */ |
||
20 | protected $weight = GraphInterface::DEFAULT_EDGE_WEIGHT; |
||
21 | |||
22 | /** |
||
23 | * Get weight of the edge |
||
24 | * |
||
25 | * @return mixed |
||
26 | */ |
||
27 | 2 | public function getWeight(): float |
|
30 | } |
||
31 | |||
32 | /** |
||
33 | * Set the weight of the edge |
||
34 | * |
||
35 | * @param float $weight - the edge weight |
||
36 | */ |
||
37 | 2 | public function setWeight(float $weight): void |
|
42 |