Commit 66dc4a51 authored by arnaudbey's avatar arnaudbey
Browse files

remove innova mention

parent 7b5e2340
......@@ -20,8 +20,8 @@ class AppKernel extends Kernel
new JMS\DiExtraBundle\JMSDiExtraBundle($this),
new JMS\AopBundle\JMSAopBundle(),
new FOS\JsRoutingBundle\FOSJsRoutingBundle(),
new Innova\WiktionaryBundle\InnovaWiktionaryBundle(),
new Innova\LexiconBundle\InnovaLexiconBundle(),
new WiktionaryBundle\WiktionaryBundle(),
new LexiconBundle\LexiconBundle(),
new Bazinga\Bundle\JsTranslationBundle\BazingaJsTranslationBundle(),
];
......
......@@ -92,11 +92,11 @@ doctrine:
auto_mapping: true
mappings:
MagicWordBundle: ~
InnovaLexiconBundle: ~
LexiconBundle: ~
lexicon:
connection: lexicon
mappings:
InnovaLexiconBundle:
LexiconBundle:
mapping: true
is_bundle: true
type: annotation
......
<?php
namespace Innova\LexiconBundle\Command;
namespace LexiconBundle\Command;
use Symfony\Bundle\FrameworkBundle\Command\ContainerAwareCommand;
use Symfony\Component\Console\Input\InputInterface;
......@@ -21,7 +21,7 @@ class EnglishImportCommand extends ContainerAwareCommand
protected function execute(InputInterface $input, OutputInterface $output)
{
$em = $this->getContainer()->get('doctrine')->getEntityManager('default');
$enForms = $em->getRepository('InnovaLexiconBundle:Inflection')->getEnglishForms();
$enForms = $em->getRepository('LexiconBundle:Inflection')->getEnglishForms();
foreach ($enForms as $enForm) {
$lemma = $this->handleLemma($enForm, $output);
......@@ -41,7 +41,7 @@ class EnglishImportCommand extends ContainerAwareCommand
private function handleInflection($subcat, $lemma, $form, $output)
{
$em = $this->getContainer()->get('doctrine')->getEntityManager('default');
$inflectionManager = $this->getContainer()->get('innova_lexicon_inflection');
$inflectionManager = $this->getContainer()->get('lexicon_inflection');
$genderNames = array(
'm' => 'masculine',
......@@ -89,22 +89,22 @@ class EnglishImportCommand extends ContainerAwareCommand
$subcats = str_split($subcat);
foreach ($subcats as $subcat) {
if (isset($genderNames[$subcat])) {
$gender = $em->getRepository('InnovaLexiconBundle:Gender')->findOneByValue($genderNames[$subcat]);
$gender = $em->getRepository('LexiconBundle:Gender')->findOneByValue($genderNames[$subcat]);
} elseif (isset($numberNames[$subcat])) {
$number = $em->getRepository('InnovaLexiconBundle:Number')->findOneByValue($numberNames[$subcat]);
$number = $em->getRepository('LexiconBundle:Number')->findOneByValue($numberNames[$subcat]);
} elseif (isset($personNames[$subcat])) {
$person = $em->getRepository('InnovaLexiconBundle:Person')->findOneByValue($personNames[$subcat]);
$person = $em->getRepository('LexiconBundle:Person')->findOneByValue($personNames[$subcat]);
} else {
if (isset($tenseNames[$subcat])) {
$tense = $em->getRepository('InnovaLexiconBundle:Tense')->findOneByValue($tenseNames[$subcat]);
$tense = $em->getRepository('LexiconBundle:Tense')->findOneByValue($tenseNames[$subcat]);
}
if (isset($moodNames[$subcat])) {
$mood = $em->getRepository('InnovaLexiconBundle:Mood')->findOneByValue($moodNames[$subcat]);
$mood = $em->getRepository('LexiconBundle:Mood')->findOneByValue($moodNames[$subcat]);
}
}
}
$language = $em->getRepository('InnovaLexiconBundle:Language')->find(2);
$language = $em->getRepository('LexiconBundle:Language')->find(2);
$criteria = array_filter([
'lemma' => $lemma,
......@@ -115,7 +115,7 @@ class EnglishImportCommand extends ContainerAwareCommand
'mood' => $mood,
]);
$inflection = $em->getRepository('InnovaLexiconBundle:Inflection')->findOneBy($criteria);
$inflection = $em->getRepository('LexiconBundle:Inflection')->findOneBy($criteria);
if (!$inflection) {
$inflection = new Inflection();
......@@ -178,11 +178,11 @@ class EnglishImportCommand extends ContainerAwareCommand
$lemmaCatName = $cat[$lemmaCat];
$lemmaCat = $em->getRepository('InnovaLexiconBundle:Category')->findOneByValue($lemmaCatName);
$lemmaSubcat = $em->getRepository('InnovaLexiconBundle:Subcategory')->findOneByValue($lemmaSubcatName);
$language = $em->getRepository('InnovaLexiconBundle:Language')->find(2);
$lemmaCat = $em->getRepository('LexiconBundle:Category')->findOneByValue($lemmaCatName);
$lemmaSubcat = $em->getRepository('LexiconBundle:Subcategory')->findOneByValue($lemmaSubcatName);
$language = $em->getRepository('LexiconBundle:Language')->find(2);
$lemma = $em->getRepository('InnovaLexiconBundle:Lemma')->findOneBy([
$lemma = $em->getRepository('LexiconBundle:Lemma')->findOneBy([
'language' => $language,
'content' => $lemmaContent,
'category' => $lemmaCat,
......
<?php
namespace Innova\LexiconBundle\Command;
namespace LexiconBundle\Command;
use Symfony\Bundle\FrameworkBundle\Command\ContainerAwareCommand;
use Symfony\Component\Console\Input\InputInterface;
......@@ -24,7 +24,7 @@ class InflectionCommand extends ContainerAwareCommand
$em = $this->getContainer()->get('doctrine')->getEntityManager('default');
$inflections = $em->getRepository('InnovaLexiconBundle:Inflection')->findByIdRange($start);
$inflections = $em->getRepository('LexiconBundle:Inflection')->findByIdRange($start);
$this->parseInflections($inflections, $start, $output);
$output->writeln('<info>Done</info>');
......@@ -60,7 +60,7 @@ class InflectionCommand extends ContainerAwareCommand
{
if ($inflections) {
$em = $this->getContainer()->get('doctrine')->getEntityManager('default');
$inflectionManager = $this->getContainer()->get('innova_lexicon_inflection');
$inflectionManager = $this->getContainer()->get('lexicon_inflection');
$output->writeln('<info>... ('.$i.')</info>');
foreach ($inflections as $inflection) {
$cleanedContent = $inflectionManager->getCleanContent($inflection->getContent());
......@@ -72,7 +72,7 @@ class InflectionCommand extends ContainerAwareCommand
$em->clear();
$i = $i + 20000;
$inflections = $em->getRepository('InnovaLexiconBundle:Inflection')->findByIdRange($i);
$inflections = $em->getRepository('LexiconBundle:Inflection')->findByIdRange($i);
$output->writeln('<info>... ('.$i.')</info>');
$this->parseInflections($inflections, $i, $output);
}
......@@ -81,7 +81,7 @@ class InflectionCommand extends ContainerAwareCommand
private function populateStart($output, $cleanedContent, $language)
{
$em = $this->getContainer()->get('doctrine')->getEntityManager('default');
$startRepo = $em->getRepository('InnovaLexiconBundle:InflectionStart');
$startRepo = $em->getRepository('LexiconBundle:InflectionStart');
$letters = preg_split('//', $cleanedContent, -1, PREG_SPLIT_NO_EMPTY);
$languageId = $language->getId();
for ($i = 0; $i < count($letters); ++$i) {
......
<?php
namespace Innova\LexiconBundle\DependencyInjection;
namespace LexiconBundle\DependencyInjection;
use Symfony\Component\Config\Definition\Builder\TreeBuilder;
use Symfony\Component\Config\Definition\ConfigurationInterface;
......
<?php
namespace Innova\LexiconBundle\DependencyInjection;
namespace LexiconBundle\DependencyInjection;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\Config\FileLocator;
......@@ -12,7 +12,7 @@ use Symfony\Component\DependencyInjection\Loader;
*
* @link http://symfony.com/doc/current/cookbook/bundles/extension.html
*/
class InnovaLexiconExtension extends Extension
class LexiconExtension extends Extension
{
/**
* {@inheritdoc}
......
<?php
namespace Innova\LexiconBundle\Entity;
namespace LexiconBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
......
<?php
namespace Innova\LexiconBundle\Entity;
namespace LexiconBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
......
<?php
namespace Innova\LexiconBundle\Entity;
namespace LexiconBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
use Doctrine\ORM\Mapping\Index;
......@@ -12,7 +12,7 @@ use JsonSerializable;
* @ORM\Table(name="lexicon.inflection", indexes={
* @Index(name="cleaned_content", columns={"cleaned_content"}),
* })
* @ORM\Entity(repositoryClass="Innova\LexiconBundle\Repository\InflectionRepository")
* @ORM\Entity(repositoryClass="LexiconBundle\Repository\InflectionRepository")
*/
class Inflection implements JsonSerializable
{
......@@ -26,12 +26,12 @@ class Inflection implements JsonSerializable
private $id;
/**
* @ORM\ManyToOne(targetEntity="Innova\LexiconBundle\Entity\Language")
* @ORM\ManyToOne(targetEntity="LexiconBundle\Entity\Language")
*/
private $language;
/**
* @ORM\ManyToOne(targetEntity="Innova\LexiconBundle\Entity\Lemma", cascade={"persist"})
* @ORM\ManyToOne(targetEntity="LexiconBundle\Entity\Lemma", cascade={"persist"})
*/
private $lemma;
......@@ -50,27 +50,27 @@ class Inflection implements JsonSerializable
private $cleanedContent;
/**
* @ORM\ManyToOne(targetEntity="Innova\LexiconBundle\Entity\Number")
* @ORM\ManyToOne(targetEntity="LexiconBundle\Entity\Number")
*/
private $number;
/**
* @ORM\ManyToOne(targetEntity="Innova\LexiconBundle\Entity\Gender")
* @ORM\ManyToOne(targetEntity="LexiconBundle\Entity\Gender")
*/
private $gender;
/**
* @ORM\ManyToOne(targetEntity="Innova\LexiconBundle\Entity\Tense")
* @ORM\ManyToOne(targetEntity="LexiconBundle\Entity\Tense")
*/
private $tense;
/**
* @ORM\ManyToOne(targetEntity="Innova\LexiconBundle\Entity\Person")
* @ORM\ManyToOne(targetEntity="LexiconBundle\Entity\Person")
*/
private $person;
/**
* @ORM\ManyToOne(targetEntity="Innova\LexiconBundle\Entity\Mood")
* @ORM\ManyToOne(targetEntity="LexiconBundle\Entity\Mood")
*/
private $mood;
......@@ -173,11 +173,11 @@ class Inflection implements JsonSerializable
/**
* Set lemma.
*
* @param \Innova\LexiconBundle\Entity\Lemma $lemma
* @param \LexiconBundle\Entity\Lemma $lemma
*
* @return Inflection
*/
public function setLemma(\Innova\LexiconBundle\Entity\Lemma $lemma = null)
public function setLemma(\LexiconBundle\Entity\Lemma $lemma = null)
{
$this->lemma = $lemma;
......@@ -187,7 +187,7 @@ class Inflection implements JsonSerializable
/**
* Get lemma.
*
* @return \Innova\LexiconBundle\Entity\Lemma
* @return \LexiconBundle\Entity\Lemma
*/
public function getLemma()
{
......@@ -197,11 +197,11 @@ class Inflection implements JsonSerializable
/**
* Set number.
*
* @param \Innova\LexiconBundle\Entity\Number $number
* @param \LexiconBundle\Entity\Number $number
*
* @return Inflection
*/
public function setNumber(\Innova\LexiconBundle\Entity\Number $number = null)
public function setNumber(\LexiconBundle\Entity\Number $number = null)
{
$this->number = $number;
......@@ -211,7 +211,7 @@ class Inflection implements JsonSerializable
/**
* Get number.
*
* @return \Innova\LexiconBundle\Entity\Number
* @return \LexiconBundle\Entity\Number
*/
public function getNumber()
{
......@@ -221,11 +221,11 @@ class Inflection implements JsonSerializable
/**
* Set gender.
*
* @param \Innova\LexiconBundle\Entity\Gender $gender
* @param \LexiconBundle\Entity\Gender $gender
*
* @return Inflection
*/
public function setGender(\Innova\LexiconBundle\Entity\Gender $gender = null)
public function setGender(\LexiconBundle\Entity\Gender $gender = null)
{
$this->gender = $gender;
......@@ -235,7 +235,7 @@ class Inflection implements JsonSerializable
/**
* Get gender.
*
* @return \Innova\LexiconBundle\Entity\Gender
* @return \LexiconBundle\Entity\Gender
*/
public function getGender()
{
......@@ -245,11 +245,11 @@ class Inflection implements JsonSerializable
/**
* Set tense.
*
* @param \Innova\LexiconBundle\Entity\Tense $tense
* @param \LexiconBundle\Entity\Tense $tense
*
* @return Inflection
*/
public function setTense(\Innova\LexiconBundle\Entity\Tense $tense = null)
public function setTense(\LexiconBundle\Entity\Tense $tense = null)
{
$this->tense = $tense;
......@@ -259,7 +259,7 @@ class Inflection implements JsonSerializable
/**
* Get tense.
*
* @return \Innova\LexiconBundle\Entity\Tense
* @return \LexiconBundle\Entity\Tense
*/
public function getTense()
{
......@@ -269,11 +269,11 @@ class Inflection implements JsonSerializable
/**
* Set person.
*
* @param \Innova\LexiconBundle\Entity\Person $person
* @param \LexiconBundle\Entity\Person $person
*
* @return Inflection
*/
public function setPerson(\Innova\LexiconBundle\Entity\Person $person = null)
public function setPerson(\LexiconBundle\Entity\Person $person = null)
{
$this->person = $person;
......@@ -283,7 +283,7 @@ class Inflection implements JsonSerializable
/**
* Get person.
*
* @return \Innova\LexiconBundle\Entity\Person
* @return \LexiconBundle\Entity\Person
*/
public function getPerson()
{
......@@ -293,11 +293,11 @@ class Inflection implements JsonSerializable
/**
* Set mood.
*
* @param \Innova\LexiconBundle\Entity\Mood $mood
* @param \LexiconBundle\Entity\Mood $mood
*
* @return Inflection
*/
public function setMood(\Innova\LexiconBundle\Entity\Mood $mood = null)
public function setMood(\LexiconBundle\Entity\Mood $mood = null)
{
$this->mood = $mood;
......@@ -307,7 +307,7 @@ class Inflection implements JsonSerializable
/**
* Get mood.
*
* @return \Innova\LexiconBundle\Entity\Mood
* @return \LexiconBundle\Entity\Mood
*/
public function getMood()
{
......@@ -341,11 +341,11 @@ class Inflection implements JsonSerializable
/**
* Set language.
*
* @param \Innova\LexiconBundle\Entity\Language $language
* @param \LexiconBundle\Entity\Language $language
*
* @return Game
*/
public function setLanguage(\Innova\LexiconBundle\Entity\Language $language = null)
public function setLanguage(\LexiconBundle\Entity\Language $language = null)
{
$this->language = $language;
......@@ -355,7 +355,7 @@ class Inflection implements JsonSerializable
/**
* Get language.
*
* @return \Innova\LexiconBundle\Entity\Language
* @return \LexiconBundle\Entity\Language
*/
public function getLanguage()
{
......
<?php
namespace Innova\LexiconBundle\Entity;
namespace LexiconBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
use Doctrine\ORM\Mapping\Index;
......@@ -10,7 +10,7 @@ use Doctrine\ORM\Mapping\Index;
* @Index(columns={"start"}, flags={"fulltext"}),
* @Index(name="language_id", columns={"language"}),
* })
* @ORM\Entity(repositoryClass="Innova\LexiconBundle\Repository\InflectionStartRepository")
* @ORM\Entity(repositoryClass="LexiconBundle\Repository\InflectionStartRepository")
*/
class InflectionStart
{
......
<?php
namespace Innova\LexiconBundle\Entity;
namespace LexiconBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
......
<?php
namespace Innova\LexiconBundle\Entity;
namespace LexiconBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
......@@ -8,7 +8,7 @@ use Doctrine\ORM\Mapping as ORM;
* Lemma.
*
* @ORM\Table(name="lexicon.lemma")
* @ORM\Entity(repositoryClass="Innova\LexiconBundle\Repository\LemmaRepository")
* @ORM\Entity(repositoryClass="LexiconBundle\Repository\LemmaRepository")
*/
class Lemma
{
......@@ -22,7 +22,7 @@ class Lemma
private $id;
/**
* @ORM\ManyToOne(targetEntity="Innova\LexiconBundle\Entity\Language")
* @ORM\ManyToOne(targetEntity="LexiconBundle\Entity\Language")
*/
protected $language;
......@@ -34,17 +34,17 @@ class Lemma
private $content;
/**
* @ORM\ManyToOne(targetEntity="Innova\LexiconBundle\Entity\Category")
* @ORM\ManyToOne(targetEntity="LexiconBundle\Entity\Category")
*/
private $category;
/**
* @ORM\ManyToOne(targetEntity="Innova\LexiconBundle\Entity\Subcategory")
* @ORM\ManyToOne(targetEntity="LexiconBundle\Entity\Subcategory")
*/
private $subcategory;
/**
* @ORM\ManyToOne(targetEntity="Innova\LexiconBundle\Entity\Gender")
* @ORM\ManyToOne(targetEntity="LexiconBundle\Entity\Gender")
*/
private $gender;
......@@ -178,11 +178,11 @@ class Lemma
/**
* Set category.
*
* @param \Innova\LexiconBundle\Entity\Category $category
* @param \LexiconBundle\Entity\Category $category
*
* @return Lemma
*/
public function setCategory(\Innova\LexiconBundle\Entity\Category $category = null)
public function setCategory(\LexiconBundle\Entity\Category $category = null)
{
$this->category = $category;
......@@ -192,7 +192,7 @@ class Lemma
/**
* Get category.
*
* @return \Innova\LexiconBundle\Entity\Category
* @return \LexiconBundle\Entity\Category
*/
public function getCategory()
{
......@@ -202,11 +202,11 @@ class Lemma
/**
* Set subcategory.
*
* @param \Innova\LexiconBundle\Entity\Subcategory $subcategory
* @param \LexiconBundle\Entity\Subcategory $subcategory
*
* @return Lemma
*/
public function setSubcategory(\Innova\LexiconBundle\Entity\Subcategory $subcategory = null)
public function setSubcategory(\LexiconBundle\Entity\Subcategory $subcategory = null)
{
$this->subcategory = $subcategory;
......@@ -216,7 +216,7 @@ class Lemma
/**
* Get subcategory.
*
* @return \Innova\LexiconBundle\Entity\Subcategory
* @return \LexiconBundle\Entity\Subcategory
*/
public function getSubcategory()
{
......@@ -226,11 +226,11 @@ class Lemma
/**
* Set gender.
*
* @param \Innova\LexiconBundle\Entity\Gender $gender
* @param \LexiconBundle\Entity\Gender $gender
*
* @return Lemma
*/
public function setGender(\Innova\LexiconBundle\Entity\Gender $gender = null)
public function setGender(\LexiconBundle\Entity\Gender $gender = null)
{
$this->gender = $gender;
......@@ -240,7 +240,7 @@ class Lemma
/**
* Get gender.
*
* @return \Innova\LexiconBundle\Entity\Gender
* @return \LexiconBundle\Entity\Gender
*/
public function getGender()
{
......@@ -250,11 +250,11 @@ class Lemma
/**
* Set language.
*
* @param \Innova\LexiconBundle\Entity\Language $language
* @param \LexiconBundle\Entity\Language $language
*
* @return Lemma
*/
public function setLanguage(\Innova\LexiconBundle\Entity\Language $language = null)
public function setLanguage(\LexiconBundle\Entity\Language $language = null)
{
$this->language = $language;
......@@ -264,7 +264,7 @@ class Lemma
/**
* Get language.
*
* @return \Innova\LexiconBundle\Entity\Language
* @return \LexiconBundle\Entity\Language
*/
public function getLanguage()
{
......
<?php
namespace Innova\LexiconBundle\Entity;
namespace LexiconBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
......
<?php
namespace Innova\LexiconBundle\Entity;
namespace LexiconBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
......
<?php
namespace Innova\LexiconBundle\Entity;
namespace LexiconBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
......
<?php
namespace Innova\LexiconBundle\Entity;
namespace LexiconBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
......
<?php
namespace Innova\LexiconBundle\Entity;
namespace LexiconBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
......