TagEndpoint   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 19
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Importance

Changes 0
Metric Value
dl 0
loc 19
c 0
b 0
f 0
wmc 1
lcom 1
cbo 2
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A getAll() 0 8 1
1
<?php
2
3
namespace Realshadow\Redtube\Endpoints;
4
5
use Illuminate\Support\Collection;
6
use Realshadow\Redtube\Entities\Tags;
7
8
9
/**
10
 * Tag Endpoint
11
 *
12
 * @package Realshadow\Redtube\Endpoints
13
 * @author Lukáš Homza <[email protected]>
14
 */
15
class TagEndpoint extends AbstractEndpoint
16
{
17
18
    /**
19
     * Get all tags
20
     *
21
     * @return Collection
22
     * @throws \RuntimeException
23
     */
24
    public function getAll()
25
    {
26
        $response = $this->call('Tags.getTagList');
27
28
        return $this->serializer
29
            ->deserialize($response, Tags::class, static::OUTPUT_FORMAT)
30
            ->flatten();
31
    }
32
33
}
34