Completed
Push — master ( d17154...1fc820 )
by Sullivan
11:02 queued 08:59
created

AbstractPersonalTranslation::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 6
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 4
c 1
b 0
f 0
nc 1
nop 3
dl 0
loc 6
rs 9.4285
1
<?php
2
3
/*
4
 * This file is part of the Sonata Project package.
5
 *
6
 * (c) Thomas Rabaix <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace Sonata\TranslationBundle\Model\Gedmo;
13
14
use Gedmo\Translatable\Entity\MappedSuperclass\AbstractPersonalTranslation as GedmoAbstractPersonalTranslation;
15
16
/**
17
 * @author Nicolas Bastien <[email protected]>
18
 *
19
 * @see https://github.com/l3pp4rd/DoctrineExtensions/blob/master/doc/translatable.md : Personal translations
20
 */
21
class AbstractPersonalTranslation extends GedmoAbstractPersonalTranslation
22
{
23
    /**
24
     * Convenient constructor.
25
     *
26
     * @param string $locale
27
     * @param string $field
28
     * @param string $value
29
     */
30
    public function __construct($locale = null, $field = null, $value = null)
31
    {
32
        $this->setLocale($locale);
33
        $this->setField($field);
34
        $this->setContent($value);
35
    }
36
}
37