EzPlatformObject::getAction()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 1
CRAP Score 2

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 2
eloc 2
c 1
b 0
f 0
nc 2
nop 0
dl 0
loc 4
ccs 1
cts 1
cp 1
crap 2
rs 10
1
<?php
2
3
/**
4
 * This file is part of Transfer.
5
 *
6
 * For the full copyright and license information, please view the LICENSE file located
7
 * in the root directory.
8
 */
9
10
namespace Transfer\EzPlatform\Repository\Values;
11
12
use Transfer\Data\ValueObject;
13
use Transfer\EzPlatform\Repository\Values\Action\ActionInterface;
14
use Transfer\EzPlatform\Repository\Values\Action\Enum\Action;
15
16
abstract class EzPlatformObject extends ValueObject implements ActionInterface
17
{
18
    /**
19
     * {@inheritdoc}
20 31
     */
21
    public function getAction()
22 31
    {
23
        return $this->getProperty('action') ?: Action::CREATEORUPDATE;
24
    }
25
}
26