Passed
Push — v9 ( 39dd2f...56991e )
by Georges
03:15
created

AggregatablePoolTrait   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 5
dl 0
loc 14
rs 10
c 1
b 0
f 0
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A isAggregatedBy() 0 3 1
A setAggregatedBy() 0 5 1
1
<?php
2
3
namespace Phpfastcache\Core\Pool;
4
5
use Phpfastcache\Cluster\ClusterPoolInterface;
6
7
trait AggregatablePoolTrait
8
{
9
    protected ?ClusterPoolInterface $clusterPool = null;
10
11
    public function isAggregatedBy(): ?ClusterPoolInterface
12
    {
13
        return $this->clusterPool;
14
    }
15
16
    public function setAggregatedBy(ClusterPoolInterface $clusterPool): static
17
    {
18
        $this->clusterPool = $clusterPool;
19
20
        return $this;
21
    }
22
}
23