Optimized for SPA

This commit is contained in:
Kevin Frantz
2019-01-05 23:52:37 +01:00
parent 9e685260e9
commit bccd6efaff
393 changed files with 253 additions and 37 deletions

View File

@@ -0,0 +1,12 @@
<?php
namespace App\Entity\Source\Primitive;
use App\Entity\Source\AbstractSource;
/**
* @author kevinfrantz
*/
abstract class AbstractPrimitiveSource extends AbstractSource implements PrimitiveSourceInterface
{
}

View File

@@ -0,0 +1,29 @@
<?php
namespace App\Entity\Source\Primitive\Name;
use App\Entity\Source\Primitive\AbstractPrimitiveSource;
use App\Entity\Attribut\NameAttribut;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Validator\Constraints as Assert;
/**
* @author kevinfrantz
*/
class AbstractNameSource extends AbstractPrimitiveSource implements NameSourceInterface
{
use NameAttribut;
/**
* @ORM\Column(type="string",length=255)
* @Assert\NotBlank()
*
* @var string
*/
protected $name;
public function __construct()
{
parent::__construct();
}
}

View File

@@ -0,0 +1,13 @@
<?php
namespace App\Entity\Source\Primitive\Name;
use Doctrine\ORM\Mapping as ORM;
/**
* @author kevinfrantz
* @ORM\Entity()
*/
class FirstNameSource extends AbstractNameSource implements FirstNameSourceInterface
{
}

View File

@@ -0,0 +1,7 @@
<?php
namespace App\Entity\Source\Primitive\Name;
interface FirstNameSourceInterface extends NameSourceInterface
{
}

View File

@@ -0,0 +1,10 @@
<?php
namespace App\Entity\Source\Primitive\Name;
use App\Entity\Source\Primitive\PrimitiveSourceInterface;
use App\Entity\Attribut\NameAttributInterface;
interface NameSourceInterface extends PrimitiveSourceInterface, NameAttributInterface
{
}

View File

@@ -0,0 +1,13 @@
<?php
namespace App\Entity\Source\Primitive\Name;
use Doctrine\ORM\Mapping as ORM;
/**
* @author kevinfrantz
* @ORM\Entity()
*/
class NicknameSource extends AbstractNameSource implements NicknameSourceInterface
{
}

View File

@@ -0,0 +1,10 @@
<?php
namespace App\Entity\Source\Primitive\Name;
/**
* @author kevinfrantz
*/
interface NicknameSourceInterface extends NameSourceInterface
{
}

View File

@@ -0,0 +1,13 @@
<?php
namespace App\Entity\Source\Primitive\Name;
use Doctrine\ORM\Mapping as ORM;
/**
* @author kevinfrantz
* @ORM\Entity()
*/
class SurnameSource extends AbstractNameSource implements SurnameSourceInterface
{
}

View File

@@ -0,0 +1,7 @@
<?php
namespace App\Entity\Source\Primitive\Name;
interface SurnameSourceInterface extends NameSourceInterface
{
}

View File

@@ -0,0 +1,14 @@
<?php
namespace App\Entity\Source\Primitive;
use App\Entity\Source\SourceInterface;
/**
* Primitive sources contain one attribut, which is not a source.
*
* @author kevinfrantz
*/
interface PrimitiveSourceInterface extends SourceInterface
{
}

View File

@@ -0,0 +1,23 @@
<?php
namespace App\Entity\Source\Primitive\Text;
use App\Entity\Source\Primitive\AbstractPrimitiveSource;
use App\Entity\Attribut\TextAttribut;
use Doctrine\ORM\Mapping as ORM;
/**
* @author kevinfrantz
* @ORM\Entity
*/
class TextSource extends AbstractPrimitiveSource implements TextSourceInterface
{
use TextAttribut;
/**
* @ORM\Column(type="string")
*
* @var string
*/
protected $text;
}

View File

@@ -0,0 +1,10 @@
<?php
namespace App\Entity\Source\Primitive\Text;
use App\Entity\Source\Primitive\PrimitiveSourceInterface;
use App\Entity\Attribut\TextAttributInterface;
interface TextSourceInterface extends PrimitiveSourceInterface, TextAttributInterface
{
}