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

CuratedPhotosRequest   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 28
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 3

Importance

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

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
A getResourcePath() 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\Model\AbstractRequest;
15
use WBW\Library\Pexels\Traits\PageTrait;
16
use WBW\Library\Pexels\Traits\PerPageTrait;
17
18
/**
19
 * Curated photos request.
20
 *
21
 * @author webeweb <https://github.com/webeweb/>
22
 * @package WBW\Library\Pexels\Model\Request
23
 */
24
class CuratedPhotosRequest extends AbstractRequest {
25
26
    use PageTrait;
27
    use PerPageTrait;
28
29
    /**
30
     * Curated photo resource path.
31
     *
32
     * @var string
33
     */
34
    const CURATED_PHOTO_RESOURCE_PATH = "/v1/curated";
35
36
    /**
37
     * Constructor.
38
     */
39
    public function __construct() {
40
        parent::__construct();
41
        $this->setPage(1);
42
        $this->setPerPage(15);
43
    }
44
45
    /**
46
     * {@inheritDoc}
47
     */
48
    public function getResourcePath() {
49
        return self::CURATED_PHOTO_RESOURCE_PATH;
50
    }
51
}
52