HasItemTrait   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 24
Duplicated Lines 0 %

Importance

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

2 Methods

Rating   Name   Duplication   Size   Complexity  
A getItem() 0 3 1
A setItem() 0 5 1
1
<?php
2
3
namespace ByTIC\Models\SmartProperties\Properties\AbstractProperty\Traits;
4
5
use ByTIC\Models\SmartProperties\Properties\Registry;
0 ignored issues
show
Bug introduced by
The type ByTIC\Models\SmartProperties\Properties\Registry was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
6
use ByTIC\Models\SmartProperties\RecordsTraits\HasSmartProperties\RecordTrait;
7
use Nip\Records\Record as Record;
8
9
/**
10
 * Trait HasItemTrait
11
 * @package ByTIC\Models\SmartProperties\Properties\AbstractProperty\Traits
12
 */
13
trait HasItemTrait
14
{
15
    /**
16
     * @var null|Record|RecordTrait
17
     */
18
    protected $item;
19
20
    /**
21
     * @return Record|null|RecordTrait
22
     */
23
    public function getItem()
24
    {
25
        return $this->item;
26
    }
27
28
    /**
29
     * @param $i
30
     * @return $this
31
     */
32
    public function setItem($i)
33
    {
34
        $this->item = $i;
35
36
        return $this;
37
    }
38
}
39