Completed
Push — master ( fecb59...e32f72 )
by Paweł
29:36
created

Rule::getExpression()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 0
crap 1
1
<?php
2
3
/**
4
 * This file is part of the Superdesk Web Publisher Rule Component.
5
 *
6
 * Copyright 2016 Sourcefabric z.ú. and contributors.
7
 *
8
 * For the full copyright and license information, please see the
9
 * AUTHORS and LICENSE files distributed with this source code.
10
 *
11
 * @copyright 2016 Sourcefabric z.ú
12
 * @license http://www.superdesk.org/license
13
 */
14
15
namespace SWP\Component\Rule\Model;
16
17
class Rule implements RuleInterface
18
{
19
    /**
20
     * @var mixed
21
     */
22
    protected $id;
23
24
    /**
25
     * @var string
26
     */
27
    protected $expression;
28
29
    /**
30
     * @var int
31
     */
32
    protected $priority;
33
34
    /**
35
     * @var array
36
     */
37
    protected $configuration = [];
38
39
    /**
40
     * {@inheritdoc}
41
     */
42 9
    public function getId()
43
    {
44 9
        return $this->id;
45
    }
46
47
    /**
48
     * {@inheritdoc}
49
     */
50 6
    public function getExpression()
51
    {
52 6
        return $this->expression;
53
    }
54
55
    /**
56
     * {@inheritdoc}
57
     */
58 9
    public function setExpression($expression)
59
    {
60 9
        $this->expression = $expression;
61 9
    }
62
63 6
    public function getPriority()
64
    {
65 6
        return $this->priority;
66
    }
67
68
    /**
69
     * {@inheritdoc}
70
     */
71 9
    public function setPriority($priority)
72
    {
73 9
        $this->priority = $priority;
74 9
    }
75
76
    /**
77
     * {@inheritdoc}
78
     */
79 6
    public function getConfiguration()
80
    {
81 6
        return $this->configuration;
82
    }
83
84
    /**
85
     * {@inheritdoc}
86
     */
87 9
    public function setConfiguration(array $configuration)
88
    {
89 9
        $this->configuration = $configuration;
90 9
    }
91
}
92