Tag::space()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 1
c 1
b 0
f 0
dl 0
loc 3
ccs 2
cts 2
cp 1
rs 10
cc 1
nc 1
nop 0
crap 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