Completed
Push — master ( 3e0714...50ebf9 )
by Gabriel
09:17
created

PdfLetters   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 34
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

Changes 0
Metric Value
wmc 4
lcom 0
cbo 2
dl 0
loc 34
rs 10
c 0
b 0
f 0

4 Methods

Rating   Name   Duplication   Size   Complexity  
A getPrimaryKey() 0 4 1
A generateTable() 0 4 1
A getParentManagerFromType() 0 4 1
A getCustomFieldsManagerClass() 0 4 1
1
<?php
2
3
namespace ByTIC\DocumentGenerator\Tests\Fixtures\Models\PdfLetters;
4
5
use ByTIC\DocumentGenerator\PdfLetters\PdfLettersTrait;
6
use Nip\Records\RecordManager;
7
use Nip\Records\Traits\AbstractTrait\RecordsTrait as AbstractRecordsTrait;
8
9
/**
10
 * Class PdfLetter
11
 * @package ByTIC\DocumentGenerator\Tests\Fixtures\Models\PdfLetters
12
 */
13
class PdfLetters extends RecordManager
14
{
15
    use PdfLettersTrait;
16
17
    /**
18
     * @inheritdoc
19
     */
20
    public function getPrimaryKey()
21
    {
22
        return 'id';
23
    }
24
25
    public function generateTable()
26
    {
27
        return 'pdf_letters';
28
    }
29
30
    /**
31
     * @param $type
32
     * @return AbstractRecordsTrait
0 ignored issues
show
Comprehensibility Bug introduced by
The return type AbstractRecordsTrait is a trait, and thus cannot be used for type-hinting in PHP. Maybe consider adding an interface and use that for type-hinting?

In PHP traits cannot be used for type-hinting as they do not define a well-defined structure. This is because any class that uses a trait can rename that trait’s methods.

If you would like to return an object that has a guaranteed set of methods, you could create a companion interface that lists these methods explicitly.

Loading history...
33
     */
34
    public function getParentManagerFromType($type)
0 ignored issues
show
Unused Code introduced by
The parameter $type is not used and could be removed.

This check looks from parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
35
    {
36
        // TODO: Implement getParentManagerFromType() method.
37
    }
38
39
    /**
40
     * @return string
41
     */
42
    protected function getCustomFieldsManagerClass()
43
    {
44
        // TODO: Implement getCustomFieldsManagerClass() method.
45
    }
46
}
47