Completed
Pull Request — master (#100)
by ARCANEDEV
14:05
created

TranslationHasBeenSet::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 8
Code Lines 6

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 7
CRAP Score 1

Importance

Changes 0
Metric Value
cc 1
eloc 6
nc 1
nop 5
dl 0
loc 8
ccs 7
cts 7
cp 1
crap 1
rs 9.4285
c 0
b 0
f 0
1
<?php namespace Arcanedev\Localization\Events;
2
3
use Illuminate\Database\Eloquent\Model;
4
5
/**
6
 * Class     TranslationHasBeenSet
7
 *
8
 * @package  Arcanedev\Localization\Events
9
 * @author   ARCANEDEV <[email protected]>
10
 */
11
class TranslationHasBeenSet
12
{
13
    /* -----------------------------------------------------------------
14
     |  Properties
15
     | -----------------------------------------------------------------
16
     */
17
18
    /** @var \Illuminate\Database\Eloquent\Model */
19
    public $model;
20
21
    /** @var string */
22
    public $attribute;
23
24
    /** @var string */
25
    public $locale;
26
27
    /** @var mixed */
28
    public $oldValue;
29
30
    /** @var mixed */
31
    public $newValue;
32
33
    /* -----------------------------------------------------------------
34
     |  Constructor
35
     | -----------------------------------------------------------------
36
     */
37
38
    /**
39
     * TranslationHasBeenSet constructor.
40
     *
41
     * @param  \Illuminate\Database\Eloquent\Model  $model
42
     * @param  string                               $attribute
43
     * @param  string                               $locale
44
     * @param  mixed                                $oldValue
45
     * @param  mixed                                $newValue
46
     */
47 45
    public function __construct(Model $model, $attribute, $locale, $oldValue, $newValue)
48
    {
49 45
        $this->model     = $model;
50 45
        $this->attribute = $attribute;
51 45
        $this->locale    = $locale;
52 45
        $this->oldValue  = $oldValue;
53 45
        $this->newValue  = $newValue;
54 45
    }
55
}
56