Tag   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 29
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
eloc 4
c 1
b 0
f 0
dl 0
loc 29
ccs 2
cts 2
cp 1
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A space() 0 3 1
1
<?php
2
3
namespace Spinen\ClickUp;
4
5
use Spinen\ClickUp\Exceptions\InvalidRelationshipException;
6
use Spinen\ClickUp\Exceptions\ModelNotFoundException;
7
use Spinen\ClickUp\Exceptions\NoClientException;
8
use Spinen\ClickUp\Support\Model;
9
use Spinen\ClickUp\Support\Relations\ChildOf;
10
11
/**
12
 * Class Tag
13
 *
14
 * @package Spinen\ClickUp
15
 *
16
 * @property string $name
17
 * @property string $tag_fg
18
 * @property string $tag_bg
19
 */
20
class Tag extends Model
21
{
22
    /**
23
     * Is resource nested behind parentModel
24
     *
25
     * Several of the endpoints are nested behind another model for relationship, but then to
26
     * interact with the specific model, then are not nested.  This property will know when to
27
     * keep the specific model nested.
28
     *
29
     * @var bool
30
     */
31
    protected $nested = true;
32
33
    /**
34
     * Path to API endpoint.
35
     *
36
     * @var string
37
     */
38
    protected $path = '/tag';
39
40
    /**
41
     * @return ChildOf
42
     * @throws InvalidRelationshipException
43
     * @throws ModelNotFoundException
44
     * @throws NoClientException
45
     */
46 1
    public function space(): ChildOf
47
    {
48 1
        return $this->childOf(Space::class);
49
    }
50
}
51