Completed
Push — ezp26175-exception_on_non_defa... ( 77d2f3...ca5fc8 )
by
unknown
39:33
created

Resource   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 36
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 6 1
1
<?php
2
3
/**
4
 * File containing the Resource class.
5
 *
6
 * @copyright Copyright (C) eZ Systems AS. All rights reserved.
7
 * @license For full copyright and license information view LICENSE file distributed with this source code.
8
 *
9
 * @version //autogentag//
10
 */
11
namespace eZ\Publish\Core\REST\Common\Values;
12
13
use eZ\Publish\Core\REST\Common\Value as RestValue;
14
15
/**
16
 * This class represents a resource.
17
 */
18
class Resource extends RestValue
19
{
20
    /**
21
     * Resource name.
22
     *
23
     * @var string
24
     */
25
    public $name;
26
27
    /**
28
     * Media Type of the resource.
29
     *
30
     * @var string
31
     */
32
    public $mediaType;
33
34
    /**
35
     * href of the resource.
36
     *
37
     * @var string
38
     */
39
    public $href;
40
41
    /**
42
     * Resource constructor.
43
     * @param $name
44
     * @param $mediaType
45
     * @param $href
46
     */
47
    public function __construct($name, $mediaType, $href)
48
    {
49
        $this->name = $name;
50
        $this->mediaType = $mediaType;
51
        $this->href = $href;
52
    }
53
}
54