Completed
Push — master ( 0afe29...1d6efb )
by WEBEWEB
01:12
created

GetVideoRequest   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 32
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

Changes 0
Metric Value
dl 0
loc 32
c 0
b 0
f 0
wmc 3
lcom 0
cbo 2
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A getResourcePath() 0 3 1
A getSubstituteName() 0 3 1
A getSubstituteValue() 0 3 1
1
<?php
2
3
/*
4
 * This file is part of the pexels-library package.
5
 *
6
 * (c) 2019 WEBEWEB
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace WBW\Library\Pexels\Model\Request;
13
14
use WBW\Library\Pexels\API\SubstituteRequestInterface;
15
use WBW\Library\Pexels\Model\AbstractRequest;
16
use WBW\Library\Pexels\Traits\IdTrait;
17
18
/**
19
 * Get video request.
20
 *
21
 * @author webeweb <https://github.com/webeweb/>
22
 * @package WBW\Library\Pexels\Model\Request
23
 */
24
class GetVideoRequest extends AbstractRequest implements SubstituteRequestInterface {
25
26
    use IdTrait;
27
28
    /**
29
     * Get video resource path.
30
     *
31
     * @var string
32
     */
33
    const GET_VIDEO_RESOURCE_PATH = "/v1/videos/videos/:id";
34
35
    /**
36
     * {@inheritDoc}
37
     */
38
    public function getResourcePath() {
39
        return self::GET_VIDEO_RESOURCE_PATH;
40
    }
41
42
    /**
43
     * {@inheritdoc}
44
     */
45
    public function getSubstituteName() {
46
        return ":id";
47
    }
48
49
    /**
50
     * {@inheritdoc}
51
     */
52
    public function getSubstituteValue() {
53
        return $this->getId();
54
    }
55
}
56