LoadLanguageData   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 15
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Importance

Changes 0
Metric Value
wmc 1
lcom 1
cbo 2
dl 0
loc 15
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A load() 0 7 1
1
<?php
2
3
namespace ClientBundle\DataFixtures\ORM;
4
5
use Doctrine\Common\DataFixtures\FixtureInterface;
6
use Doctrine\Common\Persistence\ObjectManager;
7
use ClientBundle\Entity\Lang;
8
9
/**
10
 * Class LoadLanguageData
11
 */
12
class LoadLanguageData implements FixtureInterface
13
{
14
    private $langName = 'ukraine';
15
16
    /**
17
     * @param ObjectManager $manager
18
     */
19
    public function load(ObjectManager $manager)
20
    {
21
        $language = new Lang();
22
        $language->setName($this->langName);
23
        $manager->persist($language);
24
        $manager->flush();
25
    }
26
}
27