Passed
Push — master ( 4f7192...bd6c0b )
by Gabriel
03:33
created

Records   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
wmc 3
eloc 6
c 1
b 0
f 1
dl 0
loc 21
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A registerSmartProperties() 0 4 1
A getDefaultRegistrationStatus() 0 3 1
A getModelNamespace() 0 3 1
1
<?php
2
3
namespace ByTIC\Models\SmartProperties\Tests\Fixtures\RecordsTraits\HasSmartProperties;
4
5
use ByTIC\Models\SmartProperties\RecordsTraits\HasSmartProperties\RecordsTrait;
6
use Nip\Records\RecordManager as AbstractRecords;
7
8
/**
9
 * Class Records
10
 * @package ByTIC\Models\SmartProperties\Tests\Fixtures\RecordsTraits\HasSmartProperties
11
 */
12
class Records extends AbstractRecords
13
{
14
    use RecordsTrait;
15
16
    public function registerSmartProperties()
17
    {
18
        $this->registerSmartProperty('status');
19
        $this->registerSmartProperty('registration_status');
20
    }
21
22
    public function getDefaultRegistrationStatus(): string
23
    {
24
        return 'unregistered';
25
    }
26
27
    /** @noinspection PhpMissingParentCallCommonInspection
28
     * @return string
29
     */
30
    public function getModelNamespace()
31
    {
32
        return 'ByTIC\Models\SmartProperties\Tests\Fixtures\RecordsTraits\HasSmartProperties\\';
33
    }
34
}
35