Completed
Push — language_match_api_logic ( a7e09e...cf6f59 )
by André
20:52 queued 10s
created

ObjectState::getDescription()   A

Complexity

Conditions 2
Paths 2

Size

Total Lines 8
Code Lines 4

Duplication

Lines 8
Ratio 100 %

Importance

Changes 0
Metric Value
cc 2
eloc 4
nc 2
nop 1
dl 8
loc 8
rs 9.4285
c 0
b 0
f 0
1
<?php
2
3
/**
4
 * File containing the ObjectState 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
namespace eZ\Publish\Core\Repository\Values\ObjectState;
10
11
use eZ\Publish\API\Repository\Values\ObjectState\ObjectState as APIObjectState;
12
use eZ\Publish\Core\Repository\Values\MultiLanguageDescriptionTrait;
13
use eZ\Publish\Core\Repository\Values\MultiLanguageNameTrait;
14
use eZ\Publish\Core\Repository\Values\MultiLanguageTrait;
15
16
/**
17
 * This class represents a object state value.
18
 *
19
 * @property-read mixed $id the id of the content type group
20
 * @property-read string $identifier the identifier of the content type group
21
 * @property-read int $priority the priority in the group ordering
22
 * @property-read string $defaultLanguageCode the default language of the object state group names and description used for fallback.
23
 * @property-read string[] $languageCodes the available languages
24
 *
25
 * @internal Meant for internal use by Repository, type hint against API object instead.
26
 */
27
class ObjectState extends APIObjectState
28
{
29
    use MultiLanguageTrait;
30
    use MultiLanguageNameTrait;
31
    use MultiLanguageDescriptionTrait;
32
33
    /**
34
     * @var \eZ\Publish\API\Repository\Values\ObjectState\ObjectStateGroup
35
     */
36
    protected $objectStateGroup;
37
38
    /**
39
     * The object state group this object state belongs to.
40
     *
41
     * @return \eZ\Publish\API\Repository\Values\ObjectState\ObjectStateGroup
42
     */
43
    public function getObjectStateGroup()
44
    {
45
        return $this->objectStateGroup;
46
    }
47
}
48